Reputation: 1744
I have this query:
EDITED
The problem is that after executing the query I'm getting this error:
Incorrect syntax near the keyword 'union'.
I am missing somthing?
Upvotes: 0
Views: 56
Reputation: 21520
If you take a look at the documentation at:
C. Using UNION of two SELECT statements with ORDER BY
you'll see that you can't use ORDER BY in the first query.
Remember that:
Upvotes: 2