Using "Order by" twice in a single Query
sql, sql-server, t-sql
Solution
List needed columns separated by comma:
select Date_Réserve, Heure_Réserve from réserve
order by Date_Réserve, Heure_Réserve
Problem
I have a table with 2 columns. `Date_Réserv`e(type of Date), `Heure_Réserve`(type of Time) What I want to do is select the result ordered by the `Date_Réserve` and then thie result I get is ordered by `Heure_Réserve`. this is the query I tried : ``` select * from (select Date_Réserve,Heure_Réserve from réserve order by Date_Réserve)t order by Heure_Réserve ``` But It gives me this error: The ORDER BY clause is invalid in views, inline functions, derived tables, and subqueries, unless TOP is also specified.