4 Replies Latest reply: Apr 29, 2010 11:17 AM by rmurasse RSS

    Can IF or SWITCH Statement be used inside a LOAD Statement?

      Is it possible to use an IF or SWITCH Statement inside a LOAD Statement?

      e.g.

      Table2:

      LOAD DISTINCT Product
      , IF Product = 'TRAKTOR' THEN 2 ELSE 1 END IF as Division

      RESIDENT Table1;

      How is the correct syntax to analyse the value of field A inside the LOAD statement, and create, depending on the content of value A, a new field B ?

      Thanks for any help!

      TB