Example Expression(From) | Transformation(to) |
---|---|
ename LIKE 'WARD' | ename='WARD' |
ename IN ('KING','WARD') | ename='KING' OR ename = 'WARD' |
ename=ANY/SOME('KING','WARD') | ename='KING' OR ename = 'WARD' |
deptno != ALL(10,20) | deptno != 10 AND deptno !=20 |
sal BETWEEN 2000 AND 3000 | sal >= 2000 AND sal <= 3000 |
NOT(sal<1000 OR comm is null) | sal >= 1000 AND comm IS NOT NULL |
Example Expression(From) | View Merging(tO) |
---|---|
{code:sql}CREATE VIEW emp_d10 AS SELECT * FROM emp WHERE deptno = 10;{code} WHERE empno > 11910 | {code:sql} SELECT empno FROM emp WHERE deptno = 10 AND empno > 11910;{code} |
Example Expression(From) | Sub-Query Mergin(to) |
---|---|
{code:sql}SELECT * FROM dept WHERE deptno = (SELECT deptno FROM emp WHERE empno < 12501 );{code} | {code:sql}SELECT * FROM dept WHERE deptno = <evaluated_value>;{code} |