Answer Posted / liju
nth lowest
nth lowest
*******************************************************
SELECT DISTINCT (A.sal) FROM EMP A WHERE (N-1) =
(SELECT COUNT (DISTINCT (b.sal)) FROM EMP B
WHERE b.sal<a.sal);
nth highest
*******************************************************
SELECT DISTINCT (A.sal) FROM EMP A WHERE (N-1) =
(SELECT COUNT (DISTINCT (b.sal)) FROM EMP B
WHERE b.sal>a.sal);
| Is This Answer Correct ? | 14 Yes | 3 No |
Post New Answer View All Answers
What is self referencing foreign key?
Who created postgresql?
How to start database server in postgresql?
How to display error message in postgresql?
How to execute postgres function in pgadmin?
Is postgres is free?
How to delete/drop an existing postgresql database?
Is postgresql a relational database?
What is a foreign key constraint why are such constraints important?
What is the command enable-debug?
What is character varying in postgres?
How secure is postgresql?
What is aws aurora postgres?
What is the difference between postgresql and sql?
How do you change the name of a column?