select * into #t from table1 order by ID, Name, [Desc] desc
truncate table table1
insert table1 select * from #t

解决方案 »

  1.   

    修改系统表:syscolumns中字段colid的值.
      

  2.   

    to :  CrazyFor(蚂蚁) ( ) 
    谢谢,直接修改系统表是否安全,会不会把数据库搞崩溃?各位还有什么意见?
      

  3.   

    --打开修改系统表的开关
    EXEC sp_configure 'allow updates',1  RECONFIGURE WITH OVERRIDE--先查看
    select * from syscolumns where id = object_id('表名')--再修改 cloid决定了顺序
    update syscolumns  set colid = 56 where id = object_id('表名') and name='列名' --关闭修改系统表的开关
    EXEC sp_configure 'allow updates',0  RECONFIGURE WITH OVERRIDE
    go