select a.申请号,a.方案代码,a.备案号,b.方案名称 into c from a,b where a.方案代码=b.方案代码

解决方案 »

  1.   

    select 申请号、a.方案代码、a.方案名称、备案号
    from table1 a ,table2 b
    where a.方案代码=b.方案代码
      

  2.   

    select 申请号、a.方案代码、a.方案名称、备案号
    from table1 a inner join table2 b
    on a.方案代码=b.方案代码
      

  3.   

    select 申请号、a.方案代码、a.方案名称、备案号
     into c from table1 a inner join table2 b
    on a.方案代码=b.方案代码
    删除表A,修改表C名称为A
      

  4.   

    select a.申请号,a.方案代码,a.备案号,b.方案名称 into c from a,b where a.方案代码=b.方案代码
      

  5.   

    用视图吧
    CREATE VIEW dbo.viewsge
    AS
    select a.申请号,a.方案代码,a.备案号,b.方案名称 into c from a,b where a.方案代码=b.方案代码
    要用的时候就直接从试图中取,很方便的!
      

  6.   

    这样可不可以?
    SELECT 方案类别
    INSERT INTO A
    FROM B
            WHERE A.方案代码 = B.方案代码