insert 表1 select top 10000 * from 表2

解决方案 »

  1.   

    select top 10000 * from table1
    into table2orinsert into table2
    select top 10000 * from table1
      

  2.   

    insert 表1 (列1,列2) select top 10000 (列1,列2) from 表2 where 你的条件
      

  3.   

    insert into table1
    select top 10000 * from table2
      

  4.   

    --sorry,第一种应该是
    SELECT top 10000 *
    INTO table2
    FROM table1
    --这种情况创建一个新表table2
      

  5.   

    --table2已经存在
    select top 10000 * into table2 from table1
    --table2为新表
    insert into table2
    select top 10000 * from table1
      

  6.   

    SELECT TOP 10000
    INTO table2
    from table1
    where 条件
      

  7.   

    对不起,刚才犯了个小错误,应该是这样SELECT TOP 10000 *
    INTO TABLE2
    FROM TABLE1
    WHERE 条件
      

  8.   

    select top ...这种写法是ms sql专用的吧?
      

  9.   

    你不用top的话可以用
    set rowcount 1000
    select * from table1 into table2 --table2 为新建表
    insert into table2 select * from table1  --table1已经存在,往里追加