Forum Discussion
saravanakumar28
Jun 13, 2024Copper Contributor
Performance Tuning
What is the difference between ON clause and WHERE clause in joining condition Example select * from tableA JOIN tableB on tableA.ID=tableB.ID where tableA.ID=1 select * from tableA JOIN table...
olafhelper
Jun 14, 2024Bronze Contributor
saravanakumar28 , check the execution plan of both queries if there is a difference; there won't be one.
You used only the keyword "JOIN" without anything else, so it's an implicit "INNER JOIN"; here it makes no difference where you put the filter on "Id".
But it makes a big difference if you use an "OUTER JOIN" = LEFT/RIGTH.