def find_synonym(name, what):
async with engine.acquire() as conn:
synonym = model.Synonym.__table__
res=await conn.execute(select([synonym.c.our_name]).where(and_(func.lower(synonym.c.other_name) == name.lower(),
synonym.c.category == what)))
s = await res.fetchone()
if s: return s[0]
评论列表
文章目录