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

Announcements
Join us in NYC Sept 4th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

MATCH function in a LOAD

If you use a MATCH function in a LOAD, will this create an unoptimized LOAD?  My presumption is yes, but wanted to check.

4 Replies
Anonymous
Not applicable
Author

Alexander

Yup, it will unoptimise the load.

israrkhan
Specialist II
Specialist II

According to my knowledge, unoptimize load mean, the Script which has a WHERE CLAUSE.

even it is very simple like where ID =10.

in this case for every row, the where clause will be checked, so it will take lot of time in comparison.

correct me ,if i am wrong...

Not applicable
Author

Hi, Alexander.


MATCH on large data sets faster OR.

My test:

test_data:

LOAD Floor(Rand()*100) as ID

AutoGenerate(100000000); //   Attention!!!! 100 millions rows will be generated

LET vStart = Num(Now());

test1:

LOAD ID as test1ID

Resident test_data

Where Match(ID,1,2,3,4,5,6,7,8,9,10);

LET vEnd = Num(Now())-Num($(vStart));

TRACE $(vEnd);

DROP Table test1;

LET vStart = Num(Now());

test2:

LOAD ID as test2ID

Resident test_data

Where ID=1 or ID=2 or ID=3 or ID=4 or ID=5 or ID=6 or ID=7 or ID=8 or ID=9 or ID=10;

LET vEnd = Num(Now())-Num($(vStart));

TRACE $(vEnd);

DROP Table test2;

Joseph_Musekura
Support
Support

Hi,

I think that any condition, expression used in load statement that would require a QVD (for example) to be unpacked in order to evaluate the condition, expression etc.. will lead to unoptimized mode.

Regards,