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 is not equal in sql?

708


how to enter binary numbers in sql statements? : Sql dba

711


Is primary key an index?

716


What is trigger types in sql?

726


What is query optimization in sql?

726


How to write a query to show the details of a student from students table whose

759


What is rowid in sql?

679


What is a null value?

854


What is latest version of sql?

720


What is trigger explain with example?

756


how is exception handling handled in mysql? : Sql dba

772


What is a join query?

725


Is oracle and sql same?

749


How is a process of pl/sql compiled?

777


What is dml statement?

701