11 Replies Latest reply: Jan 19, 2018 4:49 AM by Tamil Nagaraj RSS

    Condition Field Load

    Hasham Khan

      Hi,

       

      I have the following script to load in numerous tab from an excel spreadsheet. I only need to use row 1 and 2 and then transpose them. All tabs have the same format, it simply that some of them contain data in row 2 and others do not.

       

      I am getting an error "Field not found - <@2>" when there is no data in row 2 of some of the excel tabs. What is best way to get around this error.

       

      for each vSheet in 'A', 'B', 'C',...........etc

      Initial_Current_Data:

      LOAD

      @1 as xy,

      @2 as value, 

      '$(vSheet)' as table,

      FileName() as filename

      FROM

      [$(Location)]

      (ooxml, no labels, table is $(vSheet), filters(

      Transpose()

      ));

      next;