7 Replies Latest reply: Aug 8, 2014 12:17 PM by Fernando Suzuki RSS

    Why there is no FinalTable created?

    Nenad Vuković

      Hi, this sounds like a trivial case but it drives me crazy today. I am using this way in tens of apps. Maybe it is not a good day to work with QV

       

      I end up with a table called "tmpTable-1" and with no "Amt2" field.

       

      What is wrong with this script? Of course, it a test script but the principle is the same. Thanks

       

      for I = 1 to 2

           vCo = if(I = 1, 'C1', 'C2');

          

           tmpTable:

           load

                '$(vCo)' as Co,

                '$(vCo)_'&ID as Key,

                ID,

                Amt1

           from test.xlsx (ooxml, embedded labels, table is Sheet1);

       

           left join (tmpTable) load

                '$(vCo)_'&ID as Key,

                Amt2

           from test.xlsx (ooxml, embedded labels, table is Sheet2);

      next

       

      drop field Key;

       

      TableFinal:

      load * resident tmpTable

      where Amt1 <> 0 and Amt2 <> 0;

       

      drop table tmpTable;