查询存在表1 但不存在表2 的所有数据
  比如
 table 1
 T1   T12  T13
1     a         A
2            b         B
3             C         c
table 2
  T21         T22       T23
 1              a         A
  5            e          E
 6             f          F
具体查询语句如下:
select A.* from table1 A,table2 B
where A.t11<>B.t21
或者
select * form table1 where T11 not in (
select t21 from table2)

相关文章:

  • 2021-06-04
  • 2021-08-11
  • 2021-09-17
  • 2022-01-09
  • 2022-12-23
  • 2022-01-15
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-10-02
  • 2022-01-16
  • 2022-01-08
  • 2021-09-04
  • 2021-12-21
  • 2021-10-31
相关资源
相似解决方案