how to retrieve last tree records from table?
select *from emp where rownum > (select count(*)-3 from
emp);
i am using this query to get last three records from table
but its not giving any output, so please tell me what is the
error in this query.
Answer Posted / ajit nayak
select *from emp
minus
select *
from emp
where rownum <= (select count(*)-3 from
emp);
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
How many sql databases can you have on one server?
how can I make a script that can be bi-language (supports english, german)? : Sql dba
What is optimistic concurrency control? : Transact sql
What are the different types of dbms?
What is the requirement of self-join?
How do you sort in sql?
What are the different tcl commands in sql?
What is pl/sql table? Why is it used?
How do you exit in sql?
Why do we need pl sql?
Explain foreign key in sql?
How does postgresql compare to mysql?
Does sql support programming?
How to rename a table?
What can sql server reporting services do?