How do you retrieve the last N records from a table?

Answer Posted / rajat

SELECT * FROM EMP A
WHERE ROWID NOT IN
(SELECT ROWID FROM RAJ WHERE ROWNUM<=(SELECT COUNT(1) FROM RAJ )-10);

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which join condition can be specified using on clause?

508


explain the options of myisamchk to improve the performance of a table. : Sql dba

537


What is constant in pl sql?

508


Where the sql database files are stored?

476


How bulk collect improves performance?

566






What are sql functions? Describe in brief different types of sql functions?

480


what are all the common sql function? : Sql dba

573


Are stored procedures faster than queries?

514


What are the different types of sql commands?

589


What is pl sql commands?

549


Does mysql support pl sql?

615


What is the difference between local variables and global variables?

597


Write a sql query to convert all character to uppercase after hypen.

953


How do you update sql?

514


What are sql queries used for?

522