Notizen
Ohne Titel
Inhalt der Notizen (1)
Seite 1
SQL BASE QUESTION
-Write an SQL query to fetch the names of workers who earn the highest salary?
Ans;-SELECT FIRST_NAME, SALARY from Worker WHERE SALARY=(SELECT max(SALARY) from Worker);
-- Write an SQL query to fetch three min salaries from a table?
Ans;-SELECT distinct Salary from worker a WHERE 3 >= (SELECT count(distinct Salary) from worker b WHERE a.Salary >= b.Salary) order by a.Salary desc;
Informationen
- Beschreibung
- Notiz am Ohne Titel, erstellt von black dragon am 03/10/2020.
- Erstellt von
- black dragon
- Aufrufe
- 0
- Bewertung