Page History
...
Before | After |
---|---|
select * from t1 where EXISTS (select null from t2 where t2.key=t1.key); | select * from t1 where t1.key IN (select t2.key from t2); |
select * from t1 where NOT EXISTS (select null from t2 where t2.key=t1.key); | select * from t1 where t1.key NOT IN (select t2.key from t2 where t2.key is not null); |
select * from t1 where t1.key IN | select * from t1 where EXISTS |
select * from t1 where t1.key NOT IN | select * from t1 where NOT EXISTS |
select * from t1 where NOT EXISTS | select t1.* from t1, t2 where t1.key = t2.key(+) and t2.key is null |
select * from t1 where t1.key NOT IN (select t2.key from t2 where t2.key is not null); | select t1.* from t1, t2 where t1.key = t2.key(+) and t2.key is null; |
select column BETWEEN X AND Y | select (column <= X AND column >= Y) |
select column NOT BETWEEN X AND Y | select (column < X AND column > Y) |
select (column<= X AND column >= Y) | select column BETWEEN X AND Y |
select (column < X AND column > Y) | select column NOT BETWEEN X AND Y |
select t1.* from t1, t2 where t1.key = t2.key and t2.col = 10; | select t1.* from t1, (select * from t2 where t2.col = 10) inline_alias where t1.key= inline_alias.key; |
For DB2 and Oracle only select t2.* from t1, t2 where t1.key = t2.key and t1.col is null | select * from t2 where t2.key IN (select t1.key from t1 where t1.col is null ) |
scroll-ignore | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Newtabfooter |
Newtabfooter |
Newtabfooter |
Newtabfooter |
Newtabfooter |
Newtabfooter |
Newtabfooter |
| ||||||||||||||||||||||||||||||||||||||||||||||||||
Newtabfooter | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| IDERA Website | Products | Purchase | Support | Community | About Us | Resources | Legal