As others have said, listing different columns in order of priority. You can also take one more step and build logic in your own ORDER BY, so that it becomes conditional, for example.
order by case when col_location = col_something_else then
col_location
else
col_time
end
davek source
share