Sql多条件排序

多条件排序可以通过在order by语句后面使用case when then条件语句来实现。 select * from 表名 ORDER BY case when 条件 then 0 else 1 end   例子: 1.创建表case_test 共有id,case_type,case_location,case_way四个字段。 2.导入数据: INSERT INTO "XIANGZH"."c
相关文章
相关标签/搜索