how to design mapping half of source table records into one
target and remaining half into another target
Answer Posted / akash
There are 2 ways through which we can achieve this:
Through informatica transformations: Source Qualifier /
Aggregator and Expression
1. Take count through an aggregator or source qualifier.
Add a port (say record_id) from sequence generator to give
the record number.
Mark router condition as -
where record_id < = (count / 2)
send this group to one target and default group of router
to other target.
2. Use the following query in Source Qualifier:
SELECT KEY_field,
description,
(CASE WHEN ROWNUM <= ((SELECT COUNT(*) FROM TEMP_TABLE)/2)
THEN 1
ELSE 2
END) AS FLAG
FROM table_name
In the above key_field and description are the required
fields from source table.
The result will be of the type:
KEY_FIELD DESCRIPTION FLAG
1 ABC 1
2 JJJ 1
3 XYZ 2
4 PQR 2
Use a router on the condition of port FLAG to map data to
targets.
Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
What are the differences between joiner transformation and source qualifier transformation?
what is mean by complex business rule ?
What are the different versions of informatica?
HAI FRIENDS THIS KISHORE FROM KUMBAKONAM. I HAVE COMPLETED MY MCA IN SASTRA UNIVERSITY WAITING FOR MY 6 TH SEM RESULT.DURING MY PROJECT I HAVE DONE INFORMATICA COURSE AS MY AREA INTEREST COURSE IN CORE MIND TECHNOLOGIES CHENNAI.I HAVE ENQUIRY ABT ALL IT PEOPLE FOR DATAWAREHOUSING THERE IS NO OPENING FOR FRESHERS. WITH SOME EXPERIENCE ANY OTHER DOMAIN TNEN ONLY U CAN GET THAT DOMAIN(DATAWAREHOUSING) JOB.BUT I AM MORE INTEREST ON THAT TO WORK ON THAT DOMAIN(INFORMATICA).WHAT TO I DO. I AM IN HELPLESS FRIENDS/EXPORTS.WAITING FOR REPLY
What are pre and post-session shell commands?
How can one identify whether mapping is correct or not without connecting session?
Explain sessions and how many types of sessions are there?
COL1,COL2 ABC,1 XYZ,2 HERE IN COL2 VALUES 1,2 NOT STSANDARD(IE MEANS NOT FIXED VALUES LIKE OTHER SOME VALUES LIKE 10,20) O/P IS COL1,COL2 ABC,2 XYZ,1
What is blocking transformation?
How identifying bottlenecks in various components of informatica and resolving them?
tell me the rules and responsblites in our project(my project is development)
State the limitations where we cannot use joiner in the mapping pipeline?
How big was your fact table
WHAT IS EDM?WHAT IS THE USE IN INFORMATICA? chandumba2005@gmai.com
generate date / time dimension in informatica