Announcement:
wanna exchange links? contact me at sapchatroom@gmail.com.
Posted by
Admin at
Toolbox sap-dev Reply from PCorpGal on Dec 11 at 12:50 PM The MATNR field is a CHAR18 field. The visible length of MATNR appears as 000nnnnnnn (char10). You might try this approach
1. Define some temporary field: MATNR2 TYPE CHAR10. and MATNR3 TYPE CHAR10. 2. In your program, do the statements: SHIFT <table>-MATNR LEFT DELETING LEADING '0' IN CHARACTER MODE. MOVE <table>-MATNR TO <table>-MATNR2. CONCATENATE '000' <table>-MATNR2 INTO MATNR3.
resulting in MATNR3 appearing as 000nnnnnnn Also if you invoke SE37 and enter function module 'CONVERSION_EXIT_MATN1_INPUT' you can test it by entering a material number and it'll show you the resulting CHAR18 material number. Good Luck! -Emily
| | | ---------------Original Message--------------- From: pavangonuguntla2008 Sent: Friday, December 07, 2012 7:17 AM Subject: Add Zeros to a Field in Internal Table Generally we copy a fields of matnr field from vbap to our internal table ,my question is normally matnr field is like 'm-01' but i want to store in my table like '00000m-01' in matnr , please suggest me relevant answer . | | Reply to this email to post your response. __.____._ | _.____.__ |