4 Replies Latest reply: Nov 13, 2015 3:36 AM by Massimo Grossi RSS

    Syntax error in a LOAD - cannot spot it - help plz

    Friedrich Hofmann



      I have a LOAD that is a bit complicated because every month, an additional column is inserted into the list at a specific position.

      For that reason, I first have a FIRST1 LOAD to have all the fieldnames and then the fields from 33 to 45 in my example (12 months) are checked and if their name has a certain format, variables are filled with that name and an alias - otherwise, both the field_variable and the alias_variable are 'dummy_37' (for line 37 for instance).


      After all the variables have been filled, there is the actual LOAD with all the fields that I know plus those variables.

      I will paste it here. I have built those lines in Excel as I didn't want to type 12 lines of that sort ... for some reason, the lines after the first one using those variables are not recognized, the commands are not highlighted in blue. I have checked them all several times and I cannot spot the error - particularly because the first one seems fine and the next ones are exactly the same ...




      IF(LEFT('$(v_field_33)', 5) <> 'dummy', '$(v_field_33)' as $(AS_v_field_33)),
      IF(LEFT('$(v_field_34)', 5) <> 'dummy', '$(v_field_34)' as
      IF(LEFT('$(v_field_35)', 5) <> 'dummy', '$(v_field_35)' as
      IF(LEFT('$(v_field_36)', 5) <> 'dummy', '$(v_field_36)' as
      IF(LEFT('$(v_field_37)', 5) <> 'dummy', '$(v_field_37)' as
      IF(LEFT('$(v_field_38)', 5) <> 'dummy', '$(v_field_38)' as
      IF(LEFT('$(v_field_39)', 5) <> 'dummy', '$(v_field_39)' as
      IF(LEFT('$(v_field_40)', 5) <> 'dummy', '$(v_field_40)' as
      IF(LEFT('$(v_field_41)', 5) <> 'dummy', '$(v_field_41)' as
      IF(LEFT('$(v_field_42)', 5) <> 'dummy', '$(v_field_42)' as
      IF(LEFT('$(v_field_43)', 5) <> 'dummy', '$(v_field_43)' as
      IF(LEFT('$(v_field_44)', 5) <> 'dummy', '$(v_field_44)' as
      IF(LEFT('$(v_field_45)', 5) <> 'dummy', '$(v_field_45)' as





      Can anybody give me a hint as to why the first line seems fine, but all the following ones - which should be the exact same as I did them all in Excel using a formula - are not recognized?


      Thanks a lot!


      Best regards,