拆分字符进行sql查询

作者:袖梨 2022-06-30
names=Split(session("city"),"|")
i=0
条件中带又带多个or 查询语句
sql="select * from qizu where 字段 like '%"&session("字段")&"%' and recycle=1 and("
for each name in names
sql=sql+"City like '%"&names(i)&"%' or "
i=i+1
next
sql=left(sql,len(sql)-4) &") order by id desc"

相关文章

精彩推荐