SAP Tutorials Blog


DATA str_f TYPE string.

DO 15 TIMES.

  "Terminating the entire loop

  IF sy-index = 7.

    EXIT.

  ELSE.

    str_f = |{ str_f }{ COND #( WHEN str_f IS NOT INITIAL THEN `, ` ) }{ sy-index }|.

  ENDIF.

ENDDO.

"str_f: 1, 2, 3, 4, 5, 6


Serkan AKKAVAK

Computer Engineer BSc

SAP Department Manager

Contact : serkurumsal@yandex.com