How to Select 38th row details in table without using rownum ?
Answers were Sorted based on User's Feedback
Answer / narsimharaju
By using cursors we can resolve this problem..
| Is This Answer Correct ? | 12 Yes | 1 No |
Answer / jilani555
declare
cursor c is select * from emp;
s number:=0;
begin
for i in c loop
s:=s+1;
if s=6 then
dbms_output.put_line(i.empno||' '||i.ename||' '||i.sal);
end if;
end loop;
end;
| Is This Answer Correct ? | 0 Yes | 0 No |
Answer / sama
select * from table_name order by some_column LIMIT 1 OFFSET 37;
| Is This Answer Correct ? | 1 Yes | 1 No |
Answer / sandipan4allinterview
select * from Table where
(select row(MIN) from Table where
(select top 38 * from Table))
NOTE: This is without using the keyword "rownum" as mentioned in questions..
Code as SQL Server
| Is This Answer Correct ? | 4 Yes | 5 No |
Answer / sushant
select * from(
select rownum num, e.* from emp e)
where num=38;
| Is This Answer Correct ? | 0 Yes | 1 No |
Answer / debasis mohanty
Select * from Table_name
where rownum < 39
MINUS
Select * From Table_name
Where rownum < 38;
| Is This Answer Correct ? | 3 Yes | 11 No |
RMAN-08540: channel string: backup set complete, elapsed time: string
PCC-00069: Host variable "string" has unsupported datatype at line number in file string
ORA-25404: lost instance
NID-00407: Reversion of database ID failed.
IMP-00091: Above error occurred on the following function and object: string. Remaining PL/SQL blocks for this object will be skipped.
ORA-14171: cannot specify <subpartition-description> clause in CREATE|ALTER TABLE
ORA-04062: %s of string has been changed
RMAN-20310: proxy copy not found in the recovery catalog
ORA-07446: sdnfy: bad value 'string' for parameter string.
SQL*Loader-00406: If data is all generated, number to load cannot be ALL
PCC-00138: Result Set Cursors are not implemented in this precompiler
ORA-29250: Invalid index specifed in call to dbms_sql.bind_array