Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Which load script would execute faster (less execution time)?

I want to create 2 fields with the exact same data (for different transformation later), and I can think of 2 ways of doing so:

Load Script 1:

    Load

          applymap ('map_table1', map_field1)    as field1

          applymap ('map_table1', map_field1)    as field2

    From [C\...] (qvd);


Load Script 2:

    Load

        *,

          field1 as field2;

    Load

          applymap ('map_table1', map_field1)    as field1

    From [C\...] (qvd);


Which load script would run faster? Would there be any difference between the results of the 2 load scripts?

1 Solution

Accepted Solutions
maxgro
MVP
MVP

the one with 2 applymap

View solution in original post

3 Replies
maxgro
MVP
MVP

the one with 2 applymap

swuehl
MVP
MVP

Another approach could also be

MAP field1, field2 USING map_table1;

    Load

          map_field1    as field1,

          map_field1    as field2

    From [C\...] (qvd);

I've learned to be cautious with general answers to performance questions. It may depend on different properties of the data set.

Just test with your own data.

Not applicable
Author

Perform the load test couple of times and you will get the which script get better.

I think Script 2 works fast because you have only one mapping load.