etl - how to create a new record dynamically using informatica powercenter -
i have employee's leaves related data , payment related information. e.g. employee e1 has taken maternity leave year. needs paid 6 months , if on leave greater duration (like 8 months) , need create 2 records her.
one allowed duration , other extended duration.
employee leavestartdate leaveenddate total_days_taken total_days_allowed leavetype e1 1jan2013 31aug2013 242 186 ml
target expected :
employee leavestartdate leaveenddate leavetype e1 1jan2013 30june2013 ml e1 1july 2013 31aug2013 extended ml
how can create second record dynamically in informatica mapping?
generally speaking, use java transformation in informatica dynamically create new rows. however, scenarios 1 described, need create 1 row based on condition can achieve adding 2 target instances , populating second target instance conditionally (using router or filter transformation).
you can this:
create 2 sets of ports leavestartdate, leaveenddate , leavetype in expression, , calculate values accordingly. example:
leavestartdate1 -> source leavestartdate leavestartdate2 -> leavestartdate + total_days_allowed + 1
now connect first set of ports directly target instance. connect second set of ports target instance through filter. filter condition total_days_taken > total_days_allowed
. can using router, if like.
Comments
Post a Comment