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...

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 / mohammed shahid

select distinct TOP3 from emp order by rownum desc;

Is This Answer Correct ?    2 Yes 8 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Mention what pl/sql package consists of?

1041


Why schema is used in sql?

1089


How does postgresql compare to oracle/db2/ms sql server/informix?

1093


What are the differences between implicit and explicit cursors?

1109


How many types of sql are there?

1045


Is sql a backend?

1071


Explain what is sql*plus?

1196


Explain locks? : Transact sql

1053


What is the use of nvl function?

1242


what are the advantages and disadvantages of cascading style sheets? : Sql dba

1103


Hi am new to PLSQL & facing problems in writing code like in SP, Functions, so any one having some SP coding with in depth explanation please share with me my Email ID suvarnaatsuvarna@rediffmail.com Or taking tanning on this please do contact me

2067


what are the system privileges that are required by a schema owner (user) to create a trigger on a table?

1120


What are the advantages of pl sql over sql?

1071


What is the use of partition by in sql?

1043


Is pl sql and postgresql same?

1179