MSSQL遍历数据表

来源:互联网 发布:和平网络电视tv破解版 编辑:程序博客网 时间:2024/05/22 09:46
  declare   @tb   varchar(50)     declare   c   cursor   for     select   name   from   sysobjects   where   xtype='U'   and   name<>'dtproperties'     open   c     fetch   next   from   c   into   @tb     while   @@fetch_status=0     begin         print   @tb         fetch   next   from   c   into   @tb     end     close   c     deallocate   c
原创粉丝点击