Tuesday, June 26, 2018

Who's on First?

It's important to know which SQL statements happen before others. Hopefully, this list will make it obvious why you can't use an alias in a WHERE statement, and why analytic functions can only be a SELECT:
  1. From / Join
  2. Connect By
  3. Where
  4. Group By
  5. Having
  6. Select / Analytic Functions
  7. Distinct
  8. Order By
  9. Fetch / Offset

No comments:

Post a Comment