i have flat file it contains 'n' number of records, i need
to send half of the records to one target table and
Remaining half to another target table: pls full details

Answers were Sorted based on User's Feedback



i have flat file it contains 'n' number of records, i need to send half of the records t..

Answer / praveen reddy

THE ABOVE ANS IS WRONG. AGGREGATOR GIVES ONLY RECORD AS
OUT PUT TO NEXT TRANSFORMATION.YOU WILL GET ONLY ONE RECORD
TO ROUTER TRANFORMATION

Is This Answer Correct ?    5 Yes 1 No

i have flat file it contains 'n' number of records, i need to send half of the records t..

Answer / jay

SCR-->SQ-->AGGR-----
| |
| v TRG 1
--------->RTR--> /
/ \
SEQ TRG 2

First get the count of records using Aggr t/r
and use this result in router t/r and have
router condition as SEQ < (Count / 2) for TRG 1
and default for TRG 2

Is This Answer Correct ?    9 Yes 7 No

i have flat file it contains 'n' number of records, i need to send half of the records t..

Answer / babu

Hi All,

SRC==>SQ==>EXP1==>SRTR==>EXP2==>RTR==>TG1
|| || ||
SEQ1 SEQ2 ==> TG2

EXPEL NATION OF MAPPING
=======================

1.EXP1: ADD ONE OUTPUT PORT AND ASSIGN THE NEXT VAL PORT FROM SEQ1 TO OUTPUT PORT.
i.e: O_SEQ1=SEQ.NEXTVAL
2.SRTR:SORT THE COLUMNS BASED ON THE O_SEQ1 IN DESCENDING ORDER.
3.EXP2:ADD ONE OUTPUT PORT AND ASSIGN THE "NEXT VAL PORT" FROM SEQ2 TO THIS OUTPUT PORT.
i.e:O_SEQ2=SEQ2.NEXTVAL
4.RTR: GRP1(O_SEQ1>=O_SEQ2)
GRP2(O_SEQ1<=O_SEQ2)(DEFAULT GROUP)

Is This Answer Correct ?    2 Yes 0 No

i have flat file it contains 'n' number of records, i need to send half of the records t..

Answer / babu

Frnds small change in the above answer..

i.e: GRP1 :O_SEQ1>=O_SEQ2 ,GRP2: O_SEQ1<O_SEQ2
OR
GRP1 :O_SEQ1>O_SEQ2 ,GRP2: O_SEQ1<=O_SEQ2

Is This Answer Correct ?    1 Yes 0 No

i have flat file it contains 'n' number of records, i need to send half of the records t..

Answer / phani

https://community.informatica.com/servlet/JiveServlet/showImage/2-61888-1981/Half_Half_Loading_Flatfile.jpg

Is This Answer Correct ?    0 Yes 0 No

i have flat file it contains 'n' number of records, i need to send half of the records t..

Answer / sehaj

CREATE A MAPPING VARIABLE WITH AGGREGATION TYPE AS COUNT.
DEFINE ITS INITIAL VALUE AS 0.
THEN IN EXPRESSION CREATE AN OUTPUT PORT.
COUNT-SETCOUNTVARIABLE(VARIABLE NAME).
USE AN AGGREGATOR TO FIND THE TOTAL NO F RECORDS.
IN ROUTER
CREATE TWO GROUPS
IN FIRST GROUP ENTER CONDITION
COUNT<=(TOTAL NMBR F RECORDS)/2
IN SECOND GROUP ENTER CONDITION
COUNT>(TOTAL NUMBER F RECORDS)/2.

SEHAJ....

Is This Answer Correct ?    0 Yes 1 No

i have flat file it contains 'n' number of records, i need to send half of the records t..

Answer / sathish

yes aboue mentioned answer is write answer, because aggegater gives total number of records then it passes to router based on that value we cal write a condition in router

Is This Answer Correct ?    1 Yes 5 No

i have flat file it contains 'n' number of records, i need to send half of the records t..

Answer / mike



target1
src-->sq-->seq gen-->rtr--> /
\
target 2

drag the source. create an sequence generator
transformation and then pass all the data to router create
two groups in the router transformation pass it to
target...You can give the condition in the router
transformation based on your requirement. if it is like odd
and even...you can use mod function in the router
transformation.
Mod function returns 0 passit to t2 and mod function
returns 1 pass it to t1
hope this works...correct me if i was wrong

Is This Answer Correct ?    3 Yes 13 No

Post New Answer

More Informatica Interview Questions

How to go to the older version for a mapping?

0 Answers  


Describe data concatenation?

0 Answers  


Source --------- eno , ename, sal 001,ank,1000 002,behe,2000 003,raj,2500 Target ------- header :DDMMYYYY24MMSS timestamp body: 001,ank,1000 002,behe,2000 003,raj,2500 footer: count(eno),sum(sal) how to implement the same in a FF tgt?

2 Answers   CTS,


I have source like this 1:2;3. so i want to load the target as 123

4 Answers   HP,


suppose in my source flatfile i have 10000 records in that some of master table records missed table records missed then what will u do

0 Answers   Patni,






i having source, router transformation, two targets in my mapping... i given two conditions in router 1)sal >500 2)sal < 5000 --------------- my source is havig two sal records (1)1000 (2)2000 then which target will load first? will both targets are get load or single target only get load...... why?

9 Answers   Cap Gemini,


Without using any transformations how u can load the data into target?

15 Answers   IBM,


i have 1000 records in my dource table, the same i have in target ,but a new column added in target as "batchno", and this column adds no 10 for 1st 100 records and 20 for next 100 records and 30 next 100 records and vice versa. how to acheive this?

6 Answers   Thomson Reuters,


What do you understand by term role-playing dimension?

0 Answers  


1 lac of flat fles in source how to load target at a time?

4 Answers   Cap Gemini,


WHAT IS THE DIFFERENCE BETWEEN .NET AND INFORMATICA?

1 Answers  


MY SOURCE IS LIKE THIS VENKATESH,101||RAJESH,102||SIVA,103||SWATHI,104 MY REQUIRMENT IS NAME ID VENKATESH 101 RAJESH 102 SIVA 103 SWATHI 104 PLEASE PROVIDE ME THE SOLUTION

4 Answers  


Categories