Inner join vs Where

后端 未结 19 1428
庸人自扰
庸人自扰 2020-11-22 05:20

Is there a difference in performance (in oracle) between

Select * from Table1 T1 
Inner Join Table2 T2 On T1.ID = T2.ID

And



        
19条回答
  •  梦谈多话
    2020-11-22 06:00

    Although the identity of two queries seems obvious sometimes some strange things happens. I have come accros the query wich has different execution plans when moving join predicate from JOIN to WHERE in Oracle 10g (for WHERE plan is better), but I can't reproduce this issue in simplified tables and data. I think it depends on my data and statistics. Optimizer is quite complex module and sometimes it behaves magically.

    Thats why we can't answer to this question in general because it depends on DB internals. But we should know that answer has to be 'no differences'.

提交回复
热议问题