2 Replies Latest reply: Dec 8, 2017 3:51 AM by Jacques Hollands RSS

    Loading multiple files in Qlik Sense

    Jacques Hollands

      Hi there,

       

      I have been searching all over the community, but haven't been able to find an answer on what I would've thought should be a fairly simple question.

       

      I have monthly Excel sheets that have operational information.  They are all exactly the same in layout, headers and content.  The are saved as follows:

      • Ops Report - 2017 07.xlsx
      • Ops Report - 2017 08.xlsx
      • Ops Report - 2017 09.xlsx
      • Ops Report - 2017 10.xlsx

       

      ...and so on.

       

      The number of files obviously grow every month and I therefore need a script that would allow for it.  I want to bring these files into Qlik Sense, but just can't seem to get the script right. I have done this before in QlikView and that was a doddle through the use of wildcards, but this doesn't seem to work in Qlik Sense.  An example of how I did it in QlikView can be found below:

       

      LOAD

                Date,

                [Vehicle Registration],

                [Weight Loaded],

                [Fuel Cost],

                [Distance]

      FROM

      [Ops*.xlsx]

      (ooxml, embedded labels, table is Data);


      This worked really well, but I now need a similar script in Qlik Sense.  Any help would be greatly appreciated.

       

      Take care,

      Jacques

        • Re: Loading multiple files in Qlik Sense
          Pedro Bergo

          Hi Jacques,

           

          I think all these files are in the same directory. So you need to set a folder Connection 'OpsFolder'.

          Then you just use these connection as QV.

           

          LOAD

                    Date,

                    [Vehicle Registration],

                    [Weight Loaded],

                    [Fuel Cost],

                    [Distance]

          FROM [lib://OpsFolder/Ops*.xlsx]

          (ooxml, embedded labels, table is Data);

           

          []

           

          Pedro