I am trying to create a SQL View in SSMS. I am using Views because they are easier to invoke from Power BI than Stored Procedures (especially when no parameters are needed).
I start by writing and testing a SQL SELECT query with an ORDER BY clause.
When I copy and paste my query in the New View:
SSMS adds a
TOP (100) PERCENT
to my SELECT statement.Tells me that my
ORDER BY
clause (which works perfectly well in the SQL SELECT) may not work.If you click the
Help
button on the dialog, you are taken to a Microsoft "Oops! No F1 help match was found" page.
My questions are:
Is
TOP (100) PERCENT
not implied when it is left out of a SQL Select?Why would a View based on a SQL Select statement not like ORDER BY clauses?