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

Announcements
Streamlining user types in Qlik Cloud capacity-based subscriptions: Read the Details
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Double conditions tFilterRow

Hello,

 

I want to test 2 conditions with the tFilterRow component, but it don't work.

 

This is my job :

tFileList_1 :

directory : "D:/SPC/FichienSensibilite"

files : "*.dat"

tFileInputDelimited_1 :

flow's name :

((Strint)globalMap.get("tFileList_1_CURRENT_FILEPATH"))

tFilterRow_1 :

 

condition

Freq    Vide    Vaut   "Fréquence=1000Hz"

Freq    Vide    Vaut   "Temps=50µs"

Run IF :

condition :

((Integer)globalMap.get("tFilterRow_1_NB_LINE_OK")) > 0

tFileCopy_1 :

 

file's name :

((String)globalMap.get("tFile_1_CURRENT_FILEPATH"))

directory : "D:/SPC/test"

 

 

For my tFileInputDelimited_1 component, I use a metadata delimited file wich is form :

Colonne0

Date=20151202

Fréquence=1000Hz

Temps=50µs

 

Information

 

Colonne0 is a String type.

Do you have an idea to test two results on the same column ? Can you help me, please ?

 

Best regards

BastienM

 

PS : My job is in French

Labels (2)
1 Solution

Accepted Solutions
TRF
Champion II
Champion II

Keep a logical test with "OR" and change the condition before tFileCopy to:

((Integer)globalMap.get("tFilterRow_1_NB_LINE_OK")) == 2

The condition will be satisfied only for file where both records exist ("Fréquence=1000Hz" AND "Temps=50µs")

 

View solution in original post

8 Replies
med1
Creator
Creator

Hello,

 

Could you please share your job to have idea about the isse ?

 

Thanks,

TRF
Champion II
Champion II

Just select "OR" as the logical operator (as both conditions cannot be satisfied at the same time):

0683p000009Lw0u.png

Hope this helps.

med1
Creator
Creator

What is the issue ?  did you check if you put 'AND' or 'OR' option in your filter row.

 

Because in the case of 'AND' you will not have any result.

 

Med,

med1
Creator
Creator

 

So first in the value Field you should put only the value not "Frequence =1000".

and in the input column you should specify the column that you want to apply your filter.

 

Like input column = Frequence  and value 1000 ( in case of int variable else you put "1000");

 

Med,

Anonymous
Not applicable
Author

Hello,

 

To copy a file, I want to check if their are on the colonne0 "Fréquence=1000Hz" and "Temps=50

µs" not OR.

If I choose OR I will copy Files with "Fréquence=1000Hz" and "Temps=60

µs" or files with "Fréquence=5000Hz" and "Temps=50

µs"

 

I look other messages

 

Best regards

BastienM

 

TRF
Champion II
Champion II

Keep a logical test with "OR" and change the condition before tFileCopy to:

((Integer)globalMap.get("tFilterRow_1_NB_LINE_OK")) == 2

The condition will be satisfied only for file where both records exist ("Fréquence=1000Hz" AND "Temps=50µs")

 

med1
Creator
Creator

In this case you put in the column input "column0" in your both filters and add the conditions.

 

Please test it.

 

if you stil have error plus share the metadata of your file.

 

Thanks,

Med

Anonymous
Not applicable
Author

It's fine, thank you.

 

Best regards

BastienM