how will u get 1 and 3rd and 5th records in table what is
the query in oracle please help me

Answers were Sorted based on User's Feedback



how will u get 1 and 3rd and 5th records in table what is the query in oracle please help me..

Answer / sandipana

select rownum as rank,emp_id,sal from(select
lastname,salary from employees orderby salary desc)
where rownum IN(1,3,5);

Is This Answer Correct ?    1 Yes 0 No

how will u get 1 and 3rd and 5th records in table what is the query in oracle please help me..

Answer / priyank

select * from (select rownum rn,emp.* from emp) where mod
(rn,2)=1;

Is This Answer Correct ?    1 Yes 0 No

how will u get 1 and 3rd and 5th records in table what is the query in oracle please help me..

Answer / millar

ie.

select column from table_name where mod(primary_key_column,2)=1;


select employee_id from employees where mod(employee_id,2)=1

Is This Answer Correct ?    0 Yes 0 No

how will u get 1 and 3rd and 5th records in table what is the query in oracle please help me..

Answer / jhansi

It displays odd rows
select * from emp where (rowid,0) in(select rowid,mod
(rownum,2) from emp);

Is This Answer Correct ?    0 Yes 2 No

how will u get 1 and 3rd and 5th records in table what is the query in oracle please help me..

Answer / punyaslok

(select * from emp)-(select rownum,emp.* from emp order by
mod(rownum,2);

Is This Answer Correct ?    0 Yes 3 No

how will u get 1 and 3rd and 5th records in table what is the query in oracle please help me..

Answer / udaya

SELECT * FROM TABLE_NAME WHERE ROWNUM=1 AND ROWNUM=3 AND
ROENUM=5

Is This Answer Correct ?    5 Yes 32 No

Post New Answer

More Informatica Interview Questions

How informatica process data means how informatica works?

2 Answers   TCS,


if we have certain records,if i need to get 5 th rec for the first time to the target,when i run it for next time,i need to get 6th rec...like that it should process.what wil be the procedure to achieve it??

1 Answers   IBM,


what is pre and post sql and what is diff between source presql and target pre sql

1 Answers   HCL, IBM,


What is the difference between source qualifier transformations source filter to filter transformation?

0 Answers  


Can we have a Mapping without a Source Qualifier?

14 Answers   Deloitte,


How to generate a single mapping for both the historical and incremental load.

2 Answers   CSC, TATA,


How to fasten loading of 100 million distinct records in informatica? (Initially they are loaded into target without using any transformation, taking 2 hours)

3 Answers   Atriax,


in staging we are merging the data and remove the inconsistants data that type of situation what u will done and type of functions u can use

0 Answers   TCS,


if i have a delimited file as source so how can we seperate this file into three diff targets?

2 Answers   TCS,


Where do you create/define mapping parameter and mapping variable?

1 Answers  


How to improve the performance of a session using sorter transformation?

0 Answers   Informatica,


What is a taget load order?

2 Answers   IBM,


Categories