用途
JSON_ConTAINS(json_doc, val[,path]):
from sqlalchemy import func# JSON_ConTAINS returns 0 or 1, not found or found. Not sure if MySQL# likes integer values in WHERe, added == 1 just to be safesession.query(Story).filter(func.json_contains(Story.section_ids, X) == 1).all()
在顶层搜索数组时,无需指定 path 。



