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 1st and last row of table without using
group functions??

Answer Posted / rajesh

SELECT * FROM (SELECT * FROM EMP ORDER BY EMP_NO) WHERE
ROWNUM < 2

UNION

SELECT * FROM (SELECT * FROM EMP ORDER BY EMP_NO DESC)
WHERE ROWNUM < 2;

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is Data Dictionary Cache in Oracle?

1243


What is an oracle database?

1105


How to define an external table with a text file?

1125


How to export several tables together?

1105


How to display employee records who gets more salary than the average salary in the department?

1126


What is meant by a deadlock situation?

1153


Can you tell me how to add new column in existing views?how?How is possible?

1515


How to count duplicated values in a column in oracle?

1103


Explain oracle insert into command?

1157


Hi this srilatha. I comlpeted my Oracle-hrms. can u provide me interview questions on Core hr, payroll,sshr,OLM etc..

2145


How to assign a table row to a record variable?

1091


What is a trigger oracle?

1136


I have a database backup file in .db (ext) form how to conver it into .dmp (ext.) for oracle database

2183


How do I start tns listener?

1095


How index is implemented in oracle database?

1042