Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
in_prep = STATEMAP({
              KEEPINPUTkeepinput = true,
              expressions = [
                ['!isNull(__last_1.B) && __last_1.B > B','nextRound']
              ]            
            },
            in
          )
              
in_ts = TIMESTAMP({
            start = 'B+condcounter(nextRound)*10'                        
          },
          in_prep
        )  

Here, we first check, if the new starttimestamp is lower than the old one. This means, the input file has started from the beginning and nextRound is set to true.

Then the TIMESTAMP operator creates timestamps from the B attribute values and increases the concounter each time, nextRound is true. Here we use 10 as a maximum value.