Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

what are the authentication modes in sql server? : Sql dba

1116


Is sqlexception checked or unchecked?

1008


What is the usage of distinct keyword?

1111


what is commit? : Sql dba

1121


Are subqueries better than joins?

1038


explain the difference between delete , truncate and drop commands? : Sql dba

1142


Why is a primary key important?

1102


What is the function that is used to transfer a pl/sql table log to a database table?

1066


what are all different types of collation sensitivity? : Sql dba

1026


Is sql procedural language?

1011


Why do we need unique key in a table?

1002


What does data normalization mean?

1026


What are the query optimization techniques?

994


What are stored procedures used for?

1048


What is the use of %rowtype?

1086