Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
See why IDC MarketScape names Qlik a 2025 Leader! Read more
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Store values into array from Map / vlookup excel?

I'n excel there's a function called vlookup and I'm trying to reproduce that in talend by comparing two values, here's my problem, if there's a better way to do this please let me know.
I'm running two queries to a database and I want to compare the results to see if they match.
i.e.
Select color from myFavoriteColors
results = blue, red, orange
Select car, color from myCars
results = myCar1 red, myCar2 purple, myCar3 green, myCar4 blue
I want to be able to compare those results and indicate if there was a match in colors so that I can create an excel file like so
myCar1 | match
myCar2 | no match
myCar3 | no match
myCar4 | match
How can this be done?
at the moment i'm running a query that goes into a map which outputs into a javaRow, only problem is I don't know how to get those values into an array so that I can retrieve that array in another component and use it to compare it against the 2nd query? I would appreciate any help, thanks!
Labels (3)
2 Replies
Anonymous
Not applicable
Author

Hello
You can do a inner join on tMap, and get the matched rows and reject rows, then output them into two temp files.
In the next subJob, read data from these two files and use a tunite merge all the rows, sort them if need and output result into a excel file.
Best regards

shong
Anonymous
Not applicable
Author

Thanks again for the help! btw talend is an amazing tool.