用select查询表,出现很多行结果
另外有一个表,表的列和这个查询的列相同
如果把查询结果加到这个表里?

解决方案 »

  1.   

    insert into tb(a,b,c)
    select a,b,c
    from tableName
      

  2.   

    select * from tb
    union all
    select * from tc
      

  3.   

    insert ta(colist)
    select colist
    from tb
    where ...
      

  4.   

    insert into table2('id','name') values (select id ,name from table where id>100)
      

  5.   


    insert into table
    select table
    from tableName
      

  6.   


    insert into tb(a,b,c)
    select a,b,c
    from tableName
      

  7.   

    select *  into t2 from t1
      

  8.   

    insert into 表名 select * from 表