I\'m trying to create a view with an ORDER BY clause. I have create it successfully on SQL Server 2012 SP1, but when I try to re-create it on SQL Server 2008 R2
ORDER BY
Error is: FROM (SELECT empno,name FROM table1 where location = 'A' ORDER BY emp_no)
FROM (SELECT empno,name FROM table1 where location = 'A' ORDER BY emp_no)
And solution is : FROM (SELECT empno,name FROM table1 where location = 'A') ORDER BY emp_no
FROM (SELECT empno,name FROM table1 where location = 'A') ORDER BY emp_no