How to extract original records at one target & Duplicate
records at one target?
Answer Posted / sks
Hi,
If I understand your question correctly, then it is like-
How to send original (distinct) records to one target
(let's say TA) and duplicates to another target (let's say
TB).
It can simply be done as follows -
In your mapping, take the source table containing whole
records (duplicates as well). Now, take 2 source qualifier
(SQ) transformations. The first SQ should
contain 'Distinct' sql query (hope you know that) and the
output ports should go to TA table.
The second SQ should contain the following sql stmt (which
filters only the duplicate records) -
-------------------------------------------
SELECT empno, ename, job, mgr, hiredate, sal, comm, deptno
FROM (SELECT empno, ename, job, mgr, hiredate, sal, comm,
deptno, ROW_NUMBER() OVER (PARTITION BY empno ORDER BY
EMPNO) rn FROM s_assign_1_emp)
WHERE rn > 1
-------------------------------------------
I am using emp table example (hope you can understand it).
Now, the output ports of the seecond SQ should go to TB
table.
This is the simplest way of doing it. Hope it will help.
If you feel any issue, please let me know at
shrikant_rps@yahoo.com
| Is This Answer Correct ? | 1 Yes | 3 No |
Post New Answer View All Answers
explain about unit testing? in real time?
What is the session task and command task?
What is an expression transformation in informatica?
What is lookup change?
What are the reusable transformations?
What is resilience time?
draw informatica architecture 8.6 ?
What if the source is a flat-file?
What is Data Caches size?
What are the steps involved in the migration from older version to newer version of Informatica Server?
What happens when a session fails and you click on recover?
What are junk dimensions?
lookup transformation with screenshots
How to update a particular record in target with out running whole workflow?
3.how will u get information about bugs how will u rectify the bugs in realtime whch tool we are using to rectify the bugs