Last answered:

23 Aug 2023

Posted on:

21 Jul 2023

0

PLEASE HELP ME WITH IT

CAN SOMEONE PLEASE WRITE THE CODE I COULDN`T WRITE IT

4 answers ( 0 marked as helpful)
Instructor
Posted on:

21 Jul 2023

0

Hi Mustafa!
Thanks for reaching out.


Could you please explain which code are you referring to? This can help us assist you better. Thank you.


Hope this helps.
Best,
Tsvetelin

Posted on:

22 Jul 2023

0

Write a query that obtains two columns. The first column must contain annual salaries higher than 80,000 dollars. The second column, renamed to "emps_with_same_salary", must show the number of employees contracted to that salary. Lastly, sort the output by the first column.

Posted on:

29 Jul 2023

0

Hi Mustafa , best would be to utilise the previous assignment code and apply it to this exercise , giving you the code won't help you in the long run. Hope this helps


Instructor
Posted on:

23 Aug 2023

0

Hi Mustafa!
Thanks for reaching out.


Please, use the following code:

SELECT 
    salary, COUNT(emp_no) AS emps_with_same_salary
FROM
    salaries
WHERE
    salary > 80000
GROUP BY salary
ORDER BY salary; 


Hope this helps.
Best,
Tsvetelin

Submit an answer