Create a mapping which contains 2 target tables. When the
session runs for the first time it shud load Target table 1
and when it runs for second time it shud load Target
table 2.

Answers were Sorted based on User's Feedback



Create a mapping which contains 2 target tables. When the session runs for the first time it shud ..

Answer / babu

Hi,
By using mapping variable,we can achieve this logic.


i.e SRC==>TRANS==>FLT1 ==>TRG1
|==>FLT2==>TRG2


in FLT1 place a condition mod(MVAR,2)=1,in FLT2 place a
condition as mod(MVAR,2)=0

MVAR is nothing but a mapping variable.
I think all are knows how to create,declare and call the
mapping variable.
please concern me if any doughts.

Is This Answer Correct ?    9 Yes 4 No

Create a mapping which contains 2 target tables. When the session runs for the first time it shud ..

Answer / babu

Hi Zak,
By default the value of MVAR is 0.The value is
increment by at run time only.
i.e is SETVARIABLE($$MVAR,($$MVAR+1))
Let me know if u have any doughts

mail:
dwarak.vbr@gmail.com
+91-8861145051

Is This Answer Correct ?    3 Yes 0 No

Create a mapping which contains 2 target tables. When the session runs for the first time it shud ..

Answer / zak

Hi Babu,

Your logic works fine if you update the MVAR mapping
variable manually before you run the session. Is there a
way to update the MVAR within the mapping??
Thanks for your reply:)

Is This Answer Correct ?    0 Yes 0 No

Create a mapping which contains 2 target tables. When the session runs for the first time it shud ..

Answer / hai

there is an option to set the value as zero ,with out set
the value manually .

Is This Answer Correct ?    0 Yes 0 No

Create a mapping which contains 2 target tables. When the session runs for the first time it shud ..

Answer / triveni munnangi

source_>sq->expression->router->tg1
->tg2
expression:v_count decimal 10 0(variableport) setvariable($$cnt,1)
o_count decimal 10 0 (outputport) $$cnt
router:groups
t1=o_count=0
0_count=1
$$cnt variable integer 10 0 max false

Is This Answer Correct ?    0 Yes 0 No

Create a mapping which contains 2 target tables. When the session runs for the first time it shud ..

Answer / perumal

Source -> sq -> sequence Generator -> exp trans -> router
trans -> tgt1/tgt2

create variable nxt_val with next value return from seq gen
and in router give rule as mod(nxt_val,2)<>0 to load tgt1
(since first run value will be 1) and mod(nxt_val,2)=0 to
load tgt2.

Is This Answer Correct ?    2 Yes 2 No

Create a mapping which contains 2 target tables. When the session runs for the first time it shud ..

Answer / subhajit

Alternative to mapping variable:

Use sequence generator, mod on that and then finally router.

Thanks

Is This Answer Correct ?    0 Yes 2 No

Post New Answer

More Informatica Interview Questions

hi all, can anyone tell where i will get good informatica training in Pune? thanks in advance.

5 Answers   TCS,


How to Join Tables my Source is having 15 table target is one?

4 Answers   TCS,


what type of transformation is not supported by mapplets?

4 Answers   CTS,


ename,deptcount vamshi,3 kumar,5 krish,8 in o/p i want vamshi record 3 times kumar record 5 times like wise what is the logic.? give the entire logic plz

1 Answers   IBM,


How do we implement materialized view?when to use materialized view?

1 Answers   TCS,


What are pre and post-session shell commands?

0 Answers  


what is difference between COM & DCOM?

1 Answers   Satyam,


i have two coloumn emp_no sal 1 3000 2 3000 3 3000 4 4000 5 5000 6 2700 7 4500 i just need output by removing duplicate.my answer should be emp_no sal 1 3000 2 4000 3 5000 and so on.please tel me the transformation to use and if variable is used in expression then how can i give variable expression

3 Answers  


how to move the mappings from your local machine to claint place?

2 Answers  


Plz..let me know differences between Informatica 7.1 and 8.1?

3 Answers  


Define mapplet?

0 Answers  


Why you use repository connectivity?

3 Answers   Yash Technologies,


Categories