Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Can fields in a resident table be sorted using temporary tables?

Hi

I'm trying to decipher the following code. The description says that the temporary table allows sorting without adding a separate sorting field or using "DUAL":

TempPreSort:          // creating temporary table with pre-sorted fields

Load * Inline [

    ProductType

    Big

    Medium

    Small

    Misc

];

Products:              // Loading in data

Load

    ProductID

    ProductType

    Price

    DeliveryLocation

    DeliveryTime

    DeliveryCost

From [$(Desktop)\Products.xls] (biff, embedded labels, header is 1 lines, table is [Sheet1$]);

Drop Table TempPreSort

My Questions:

  1. Does TempPreSort affect Products load at all? Should data in Products be grouped/ordered according to the order defined in TempPreSort ?
  2. If TempPreSort affect Products load ..
    1. does TempPreSort have to be created before Products load?
    2. would any grouping/ordering be removed when TempPreSort is dropped immediately after Products load?
1 Solution

Accepted Solutions
swuehl
MVP
MVP

Your TempPreSort table defines the load order of your ProductType field, if all field values are listed.

If you want to use this order, set sort option to 'load order' in sort tab.

edit:

1. Yes. Yes.

2. Yes. No.

View solution in original post

1 Reply
swuehl
MVP
MVP

Your TempPreSort table defines the load order of your ProductType field, if all field values are listed.

If you want to use this order, set sort option to 'load order' in sort tab.

edit:

1. Yes. Yes.

2. Yes. No.