0 Replies Latest reply: Jul 28, 2016 1:57 PM by Vladimir Komarov RSS

    Using "normal" WHERE clause in DataMarket extraction

    Vladimir Komarov

      I am trying to build a process of extracting some data from Qlik DataMarket and I am trying to understand the concept behind the automatically generated extraction script.


      Here are the options I've selected in the DataManager:

      Screen Shot 2016-07-27 at 9.59.28 AM.png

      Screen Shot 2016-07-27 at 9.59.18 AM.png


      Just want to get the "Most Recent" (whatever that means) data for Chicago, IL.


      Based on these selections, Qlik has generated the script for me:


      [Weather in 50 cities worldwide]:

      LOAD "Country",



          "Average of the 24 hourly cloud cover observations as a percentage";

      SQL SELECT * FROM "52kv"

      WHERE "8vq5" = "1c"

            AND "8vq6" = "p"

            AND TIME = MOST RECENT;


      My question is: WHY SO COMPLICATED WHERE CLAUSES????

      I am assuming that "8vq5" = "1c" means "COUNTRY" = "US" and "8vq6" = "p" means "CITY" = "CHICAGO",


      And "MOST RECENT" is simply the last day!


      Here is how the DM Where Clause looks like for the "all inclusive" case:

      WHERE  "8vq6" = "p."


      I could not find any information about mapping these codes to the "normal and readable" conditions.

      I am actually trying to build a script to extract a specific set of data (for flexible Date ranges and for specific locations) and I need to have these codes mapped to my other fields in other tables.


      I know I can extract the WHOLE data set into QVD and load the specific set from there, but I am trying to optimize my script loading and this approach is definitely not the best one.



      Any suggestions will be really appreciated!