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

Equivalent to Ab Initio Join with DB Component

Hi,

I have a flow of data that I need to join to a database, selecting * where database.field = input.field

I am using informix

Any ideas please,

John.
Labels (2)
6 Replies
Anonymous
Not applicable
Author

This can be done very easily with the tMap or with the tJoin.
Regards,
Anonymous
Not applicable
Author

Thanks for the response

Surely what you are suggesting would mean me reading the whole of the required table into the tjoin or tmap, and not just selecting the required record from the database ?
Anonymous
Not applicable
Author

Can you give precise details about what you really want to do ?
Anonymous
Not applicable
Author

Thanks for the response,

I have a file being read that contains a single column (row_id), for each record in the flow I want to query a database for something like;

select rating_id from rating where row_id = the row_id from the input flow

The output flow will look like, row_id, rating_id

You initially suggested a join or map, but this would mean reading all the records from the database ? If the table has 3.5 million records but the flow only 100 then this would not be very efficient.

I hope this makes sense, appreciate your help.
Anonymous
Not applicable
Author

You're right, tMap load all your lookup table in memory or on disk.
I perfectly understand your request. The solution to resolve your problem is to use the difference between iterate and flow links :
To anwser to your request, you should design a job like
tFileInputDelimited -> tFlowToIterate -> (iterate) -> tMySQLinput -> ...
HTH,
Anonymous
Not applicable
Author

yep, this works fine

thanks for your help