write a sql query following table?
col1 col2
1 2
1 2
1 2
3 4
3 4
5 6
i want the output like
unique duplicate
col1 col2 col1 col2
1 2 1 2
3 4 1 2
5 6
Answer / vaibhav jogale
We can achieve this using With clause
insert into TEST_UNIQ (col1,col2)
with Ct_Test as (
select col1,col2,row_number () over (partition by col1,col2 order by col1,col2)Rw_no
from test123)
select col1,col2 from Ct_Test where rw_no=1
/
insert into TEST_DUp (col1,col2)
with Ct_Test as (
select col1,col2,row_number () over (partition by col1,col2 order by col1,col2)Rw_no
from test123)
select col1,col2 from Ct_Test where rw_no>1
/
| Is This Answer Correct ? | 1 Yes | 0 No |
What is a standalone command task?
What are the different threads in DTM process?
What is DR strategy for Informatica project?
i have a source of n records.i have to load n+5 records to my target.What is the procedure??????plz tell me.....
How will you display 10-15 letters from a name? (for ex: name="sivasubram'aniam'ramakrishnan". o/p wanted="aniam")
How will you update the row without using update statergy?
How to display session logs based upon particular dates. If I want to display session logs for 1 week from a particular date how can I do it without using unix.
if i have a delimited file as source so how can we seperate this file into three diff targets?
Is LOAD MANAGER AND LOAD BALANCER same in informatica?
Can you start a session inside a batch individually?
Define sessions in informatica etl?
whether Sequence generater T/r uses Caches? then what type of Cache it is