您好,欢迎来到三六零分类信息网!老站,搜索引擎当天收录,欢迎发信息

让sql语句不排序,按照in语句的顺序返回结果_MySQL

2024/6/10 21:37:24发布21次查看
bitscn.com
mysql:
select * from event where eventid in(443,419,431,440,420,414,509)  order by instr(',443,419,431,440,420,414,509,',concat(',',eventid,','))
oracle:
select name from order where oderid in(111,222,333,444,555,666)order by instr('111,222,333,444,555,666',orderid)
bitscn.com
该用户其它信息

VIP推荐

免费发布信息,免费发布B2B信息网站平台 - 三六零分类信息网 沪ICP备09012988号-2
企业名录 Product