+ 1

write SQL query for following To list all the columns of the table 'employee' in ascending order of department number and descending order of salary.

15th Dec 2016, 4:18 PM
DHEERAJ
DHEERAJ - avatar
2 odpowiedzi
+ 3
SELECT * FROM employee ORDER BY dept_number ASC AND ORDER BY salary DESC;
16th Dec 2016, 11:32 AM
Sachin Artani
Sachin Artani - avatar
+ 2
SELECT * FROM employee ORDER BY salary, departmentNumber ASC or SELECT * FROM employee ORDER BY salary, departmentNumber since by default any column after ORDER BY, would be order by ASC SYNTAX: ----------- SELECT column-names FROM table-name WHERE condition ORDER BY column-names
16th Dec 2016, 3:17 AM
lowshuen