Hello
I was testing the features of Oracle Developer Tools for VS Code (SQL and PLSQL) and found a minor problem.
It occurs when using the SQL Monitor function on SQL with the /*+ leading */ hint.
For example, I would like to use the SQL Monitor feature for the query below.
select /*+ leading(e2 e1 e3 e4) use_nl(e1) */
e1.mgr, e2.empno, e3.ename, e4.deptno, sum(e2.sal + e3.sal + e4.sal) as total_sal
from emp e1, emp2 e2, emp3 e3, emp4 e4
where e1.empno = e2.empno
and e2.empno = e3.empno
and e3.empno = e4.empno
group by e1.mgr, e2.empno, e3.ename, e4.deptno;
Run the SQL Monitor function. (Ctrl + Alt + R)
When you check the SQL Monitor results, existing hints (leading etc..) will be invalidated due to the added "Monitor" hint.
select /*+Monitor*/ /*+ leading(e2 e1 e3 e4) use_nl(e1) */
e1.mgr, e2.empno, e3.ename, e4.deptno, sum(e2.sal + e3.sal + e4.sal) as total_sal
from emp e1, emp2 e2, emp3 e3, emp4 e4
where e1.empno = e2.empno
and e2.empno = e3.empno
and e3.empno = e4.empno
group by e1.mgr, e2.empno, e3.ename, e4.deptno;
Due to this phenomenon, the execution plan changes, and the SQL execution plan I want cannot be properly analyzed.
I would appreciate it if you could fix this issue.
Thank you.