TABLE1 和TABLE2 表的关联字段是怎样的?

解决方案 »

  1.   

    select a.A,a.B,a.C,a.D,
    b.B,b.C,b.D
    from DB1..TABLE1 a ,DB2..TABLE2 b
    where a.A=b.A
      

  2.   

    只显示一个字段:
    select 字段 from DB1..TABLE1
    union
    select 字段 from DB2..TABLE2
      

  3.   

    还是有问题!哎!!
    我用select * from DB1..TABLE1
    union
    select * from DB2..TABLE2
    一样的记录会显示两次!
    想显示全部的记录,但是名字相同的只显示一次
      

  4.   

    select * from DB1..TABLE1 where [名字] not in (select distinct [名字] from DB2..TABLE2)
    union
    select * from DB2..TABLE2
      

  5.   

    显示为: A,B,C,D,E,F, 怎么能使用 union 呢??