I have some questions related with SQL query optimization (Oracle 10g Release 2).
It's like this:
SELECT X."COL1", Y."COL8"
FROM "TBL1" X INNER JOIN "TBL2" Y ON (X."ID" = Y."XID") WHERE X."COL4" = 'xpto';
select x.col1, y.col8
from tbl1 x, tbl2 y
where x.id = y.xid and x.col4 = 'xpto';
I usually code queries like "Query B", but recently a software tester told me that I should code like "Query A" and told me this:
1 - you should always use upper case.
2 - you should put quotes in column and table names
3 - you should use the JOIN syntax because it's the recommended syntax (ISSO/IEC 9075 SQL:2003)
And he justifies this with performance improvements.
And my questions are:
A) Does this make any sense?
B) Is the JOIN syntax better than the Oracle syntax (+) in terms of performance? Does it make any difference?
C) Does the upper case and quotes make any improvements?
D) Does any of this influences SQL statement processing phases?
Disclaimer: Advice is provided to the best of my knowledge but no implicit or explicit warranties are provided. Since the advisor explicitly encourages testing any and all suggestions on a test non-production environment advisor should not held liable or responsible for any actions taken based on the given advice.