1.连接
---内连接
select * from dali.test1 a, dali.test2 b where a.a=b.a;
---左连接
select * from dali.test1 a, dali.test2 b where a.a=b.a(+);
---右连接
select * from dali.test1 a, dali.test2 b where a.a(+)=b.a;
---完全连接
select * from dali.test1 a, dali.test2 b where a.a=b.a(+)
union
select * from dali.test1 a, dali.test2 b where a.a(+)=b.a;
---迪卡尔
select * from dali.test1, dali.test2;
判断是否为空:
在SQl Server中为ISNULL(field1,0)
在Oracle中为NVL(field1,0)