数据库中存在0,1,2.....或者1,null,2 排序时让0或者null在最后的sql语句

 select * from yryz_products_t order by isnull(sort),sort; 
 
 select * from yourtable order by cast(sort as int);   此sql为转换

相关文章:

  • 2022-12-23
  • 2022-02-05
  • 2021-12-04
  • 2021-10-17
  • 2021-10-19
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2021-07-05
  • 2022-03-01
  • 2022-12-23
  • 2021-06-01
相关资源
相似解决方案