Write a query to get last 10 records from the table.
Answer Posted / jprakash025
select * from emp
minus
select * from emp
where
rownum<=(select count(*)-10 from emp);
or
SQL> select * from
2 (select rownum a, emp.* from emp)
3 where
4 a>(select max(rownum)-10 from emp);
| Is This Answer Correct ? | 24 Yes | 2 No |
Post New Answer View All Answers
what are the authentication modes in sql server? : Sql dba
Is sqlexception checked or unchecked?
What is the usage of distinct keyword?
what is commit? : Sql dba
Are subqueries better than joins?
explain the difference between delete , truncate and drop commands? : Sql dba
Why is a primary key important?
What is the function that is used to transfer a pl/sql table log to a database table?
what are all different types of collation sensitivity? : Sql dba
Is sql procedural language?
Why do we need unique key in a table?
What does data normalization mean?
What are the query optimization techniques?
What are stored procedures used for?
What is the use of %rowtype?