First of all we should know that logical and physical order of query execution are different but result must be the same. Every DBMS can optimize the order in which parts of query are executed for performance reason. However that rearrangement must not influence the final result. The query must return the same records as …