Is it possible to provide the direction once for all columns in an order by statement?
i.e.
select *
from my_table
order by name desc, type desc
can you write the same thing using “desc” once?
Maybe something similar to this? (this doesn’t work)
select *
from my_table
order by (name, type) desc
No. The SQL standard doesn’t allow that.
Having said that, there may be some RDBMS that do support a syntax like that. I’m just not aware of any.