Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I am new to talend and facing issues while trying to implement the logic below.
I need to translate a legacy data from oracle to postgres and below is the sample structure of the postgres target table.
tableseq(db sequence) casenumber legacynumber statusofcase
1 123 789 A
2 123 678 B
3 123 456 C
i have created various filters in the tmap component to insert the data in above format.
But for update scenarios i have taken my key as casenumber but i want to update the status of the record where the legacynumber is 456.
i cant take the legacynumber as key because a part of this update i will also need to update the legacynumber column to the some new number like 100.
basically i m trying to acheive below SQL functionality in talend.
update tableA set legacynumber=100 where legacynumber=456 and casenumber=123;
any inputs will be highly appreciated as i ran out of the options and needs the resolution ASAP.
Regards,
Veearr
Hello,
Do you use any filter in tMap component? Could you please post your tMap screenshots here? Which will be helpful for get more information from situation.
Best regards
Sabrina
Hi, in TMAP update output set a filter expression on the output expression filter field :
your_row.legacynumber == 456 && your_row.casenumber=123
Send me Love and Kudos
yes i have filter on the tmap to filter the records to insert or update flow.
i thought applying output filter will filter the incoming records flow to the target.
in the incoming records i have case number 123 and legacynumber 100 and in the prev legacy number 456.but where can i mention to filter the target dataset for legacy number 456?
if i apply your_row.legacynumber == 456 && your_row.casenumber=123 this will only filter the data that goes into target but it wnt restrict the update to 456 legacy number.
Please correct my understanding.