350 views
0 votes
0 votes
i generally read everywhere that SQL has no order of execution and it depends on the optimizer the best order possible is followed but we generally follow some order while evaluating the sql query i came across this order and i also find it logically right

1. FROM
2. ON
3. OUTER
4. WHERE
5. GROUP BY
6. CUBE | ROLLUP
7. HAVING
8. SELECT
9. DISTINCT
10 ORDER BY
11. TOP

can anyone throw more light on this

Please log in or register to answer this question.

Related questions

1 votes
1 votes
1 answer
2
tusharb asked Mar 27, 2022
700 views
I want to join the two tables of movies and actors and then output only those results that have gender =”F”, can you tell me where I am going wrong?
0 votes
0 votes
0 answers
3
aditi19 asked May 8, 2019
814 views
how to write the query for natural join on three relations in SQL using the NATURAL JOIN clause?
0 votes
0 votes
0 answers
4
kd..... asked Apr 30, 2019
688 views
Here why does the 5th query select * from employees natural join works_on where PID = 'X' AND PID='Y'; is not workingThe queries are The output are