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

Announcements
Qlik GA: Multivariate Time Series in Qlik Predict: Get Details
cancel
Showing results for 
Search instead for 
Did you mean: 
INESBK
Creator
Creator

Use of a tmap field in a query for tMsSqlInput

Hi,

I would use a field that exist in tmap to use it with query in tMsSqlInput like this 

"select * from Table
where name="+row1.name

But when i run the job I get this error

 

0683p000009Lum3.png

Can you help me please ?

Thanks in advance.

 
Labels (2)
14 Replies
TRF
Champion II
Champion II

So, 2 options:

1- follow the link from the previous response

2- get the lines into a tHashOutput the reuse this content for the join as you did in the tMap

Except if you have millions records, it should works.

Based on your job, here is what it should looks like (errors are normal, components are not updated):

0683p000009Lurq.png

 

INESBK
Creator
Creator
Author

I have millions of lines so I will follow the first soltion and I will keep you informed.

Thanks a lot 0683p000009MACn.png

INESBK
Creator
Creator
Author

Thanks for your help this solves my problem.

But just a question,the manner  of browse the table and do the research line by line will take a lot of time not?
If I use to load once it must be faster yes/no ?

TRF
Champion II
Champion II

It depends.

If most of the rows from main flow are linked with just few rows from the lookup, it should be efficient to use "Reload at each time (cache)" option to get only the required rows from database. Of course, columns used as criteria are supposed to be indexed on database side.

Else, if each row from main flow is linked with a different rows from the lookup you'll have to load all the rows from the lookup table, so "Load once" is the option in such a case.

INESBK
Creator
Creator
Author

Thanks a lot 0683p000009MACn.png