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 find the First and Last Observation from the table:
Ex: OBS Name Sal Ans like: OBS Name Sal
105 E 5000--> 105 E 5000
102 B 2000 104 D 4000
103 C 3000
101 A 1000-->
104 D 4000

Answer Posted / arjun

select * from tablename where rowid=1
union
( select * from tablename
intersect
select * from tablename where rowid = ( select max(rowid)
from tablename));

Is This Answer Correct ?    0 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What problem one might face while writing log information to a data-base table in pl/sql?

1068


What makes a good primary key?

982


How we can update the view?

1007


What is meant by truncate in sql?

1008


What happens when a trigger is associated to a view?

845


What are the differences between implicit and explicit cursors?

1004


Is there a 64 bit version of ssms?

897


Suppose a student column has two columns, name and marks. How to get name and marks of the top three students.

956


What is write ahead logging in sql server?

990


How many parts of a pl sql block are optional?

1035


what is rollback? : Sql dba

1024


what is primary key? : Sql dba

957


Which table is left in left join?

956


How do I view stored procedures?

918


What are the differences between in and exists clause?

1051