temptours+tours
This commit is contained in:
12
engine/engine_components/classement.py
Normal file
12
engine/engine_components/classement.py
Normal file
@ -0,0 +1,12 @@
|
||||
from typing import Optional, Dict
|
||||
|
||||
def get_classement_by_tag(cur, classement_table: str, tag: str) -> Optional[Dict]:
|
||||
pattern = f"%*{tag}*%"
|
||||
sql = f"""
|
||||
SELECT cla_info_dossard, con_id, cla_list_tag
|
||||
FROM `{classement_table}`
|
||||
WHERE cla_list_tag LIKE %s
|
||||
LIMIT 1
|
||||
"""
|
||||
cur.execute(sql, (pattern,))
|
||||
return cur.fetchone()
|
||||
Reference in New Issue
Block a user