Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
Rohitash
Contributor
Contributor

Mapping Two File

Hi Team,

 

There is a new requirement that came up and it's quite tricky.

 

Consider , I have two files File A and File B.

 

File A           File B             Output

---------       -------------        -------------

Col A           Col A             Col A

A                     A                    A

B                     B                   B

C                     #                   C

DD                  ##                 DD

 

which means  Col A value "C" should be matched with "#" and output should be "C"

similarly , means Col A value "DD" should be matched with "##" and output should be "DD".

 

How does matching will perform on this situation?

 

Kindly assist.

Labels (5)
11 Replies
Rohitash
Contributor
Contributor
Author

Inner join is not possible, if I add rownum.

Because row count is different.

 

File a have 50 records , whereas File B has 10 records. As a reference I'll be using only COL_C column from File B.

 

Any alternative suggestion, will be appreciable.

 

Thanks You so much for assisting me.

 

PhilHibbs
Creator II
Creator II

If FILE_B can ever contain ## in both COL_A and COL_B then you would need a fourth lookup that does a cross join, which I think you would do by having a fixed key value rather than a variable column. Actually it might be best to do the second and third lookups that I suggested by having a dummy column containing '##' for the looked-up COL_B and COL_A values respectively.