Skip to main content
Announcements
Introducing Qlik Answers: A plug-and-play, Generative AI powered RAG solution. READ ALL ABOUT IT!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Not Match Function_ Problem

Hi All,

I want to eliminate data on basis of NOT Match function but i am not getting expected results.

Lets say my code is

LET Var1 = Today()- 1;

Load * from XYZ.QVD

Where Not mact (Date1, '$(Var1)')

But still I am getting Today()- 1 data.

Even if write like:

Load * from XYZ.QVD

Where Not mact (Date1, '11/23/2014').

Still I am getting 11/23/2014 data.

The way I am eliminating With Not match is correct? or is there an another way?

BR ,

Neehu

1 Solution

Accepted Solutions
Gysbert_Wassenaar

Try this:


LET Var1 = num(Today() - 1);


Load * from XYZ.QVD

Where num(Date1) <> $(Var1);


talk is cheap, supply exceeds demand

View solution in original post

6 Replies
Gysbert_Wassenaar

Try this:


LET Var1 = num(Today() - 1);


Load * from XYZ.QVD

Where num(Date1) <> $(Var1);


talk is cheap, supply exceeds demand
Not applicable
Author

HI Gysbet,

WHat if I want to eliminate two dates with two variables?

Gysbert_Wassenaar

Use two clauses: Where ...condition1... or ...condition2...


talk is cheap, supply exceeds demand
Not applicable
Author

Cant I use like this:?

LET Var1 = NUm(Today()- 1);

LET Var2 = Num(Today()- 2);


Load * from XYZ.QVD

Where Not match (Date1, '$(Var1)', '$(Var2)')

rubenmarin

Hi, are you sure about the date format stored in xyz.qvd?

If it's not MM/DD/YYYY (maybe Date1 also has the time part?) you can try:

Load * from XYZ.QVD

Where Not match (Date(Date1, 'MM/DD/YYYY'), '11/23/2014').

Gysbert_Wassenaar

Maybe. It depends on the format of the Date1 field. You may have to use the date function as Ruben Marin says above.


talk is cheap, supply exceeds demand