ABAP - increment an integer

Posted by Ben on Stack Overflow See other posts from Stack Overflow or by Ben
Published on 2010-06-02T13:01:35Z Indexed on 2010/06/02 13:03 UTC
Read the original article Hit count: 347

Filed under:

Hi there,

sometimes ABAP drives me crazy with really simple tasks - as incrementing an integer within a loop...

Here's my try:

METHOD test.

  DATA:                 lv_id TYPE integer.

  lv_id = 1.

  LOOP AT x ASSIGNING <y>.
    lv_id = lv_id+1.
  ENDLOOP.

ENDMETHOD.

This gives me a strange error I can hardly translate to english..

© Stack Overflow or respective owner

Related posts about abap