欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页  >  数据库

sqlserver中将varchar类型转换为int型

程序员文章站 2022-06-02 08:07:18
...

无详细内容 无 select * from yourtable order by cast(yourcol as int); select * from yourtable order by convert(int,yourcol);

select * from yourtable order by cast(yourcol as int); 

select * from yourtable order by convert(int,yourcol);