ABAP中加前导零和去前导零方法

文章目录

      • 1 Introduction
      • 2 Method

1 Introduction

In the sap there are two method for leading zero. We can use function
or use the below the method .

2 Method

SELECT *  INTO TABLE @DATA(IT_ITEM)

FROM MARA .


 LOOP AT IT_ITEM ASSIGNING FIELD-SYMBOL(<FS_DATA>).
 <FS_DATA>-MATNR = |{ <FS_DATA>-MATNR ALPHA = OUT }|.
 ENDLOOP.


SELECT *  INTO TABLE @DATA(IT_ITEM)

FROM MARA .


 LOOP AT IT_ITEM ASSIGNING FIELD-SYMBOL(<FS_DATA>).
 <FS_DATA>-MATNR = |{ <FS_DATA>-MATNR ALPHA = IN }|.
 ENDLOOP.

你可能感兴趣的:(ABAP,SAP)