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...


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



write a sql query following table? col1 col2 1 2 1 2 1 2 3 4 3 4 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

Post New Answer

More Informatica Interview Questions

how u know when to use a static cache and dynamic cache in lookup transformation.

9 Answers   Accenture,


task is running successfully but data is not loded why?

2 Answers  


What is a surrogate key?Why we use it in a mapping?Pl give an example.

4 Answers   PCS,


performance wise which one is better in joiner and lookup transformation?why?explain clearly?

1 Answers   IBM,


Which is the t/r that builts only single cache memory?

0 Answers  


What does cheating measurement mean?

0 Answers  


Hi, Can you please send me the Informatica 8 certification exam dumps to my email id rwork.san@gmail.com Thanks, Revathi.

6 Answers   CTS,


How can i catch the Duplicate Rows From SorterTrans in a Seperate Target Table ?

2 Answers  


To achieve the session partition what r the necessary tasks u have to do?

1 Answers  


What are different types of transformations available in informatica?

0 Answers  


How to create a non-reusable instance of reusable transformations?

0 Answers   Informatica,


Can any one give me a real time example for FACT TABLE & DIMENSIONAL TABLE?

2 Answers  


Categories