Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

upload source list me01

Former Member
0 Likes
1,591

any one use this FM ME_MAINTAIN_SOURCE_LIST_NEW

for uploading source list??

do you have an example.

1 REPLY 1
Read only

Former Member
0 Likes
1,077

Hi,

Try the below function module ME_UPDATE_SOURCES_OF_SUPPLY which is being used by standard transaction ME01.

sample code

REPORT ZTEST.

DATA: BEGIN OF XORD OCCURS 50.

INCLUDE STRUCTURE EORD.

DATA: UPDKZ,

END OF XORD,

YORD type table of EORD with header line.

clear xord.

clear yord.

xord-MATNR = '100-100'.

xord-WERKS = '3000'.

xord-ZEORD = '00001'.

xord-ERDAT = '20080403'.

xord-ERNAM = 'SAPDEV02'.

xord-VDATU = '20080403'.

xord-BDATU = '20100510'.

xord-LIFNR = '0000001000'.

xord-FLIFN = 'X'.

xord-EKORG = '1000'.

xord-UPDKZ = 'U'.

append xord.

move-corresponding xord to yord.

append yord.

CALL FUNCTION 'ME_UPDATE_SOURCES_OF_SUPPLY' IN UPDATE TASK

EXPORTING

I_CHANGEDOCUMENT = 'X'

TABLES

XEORD = XORD

YEORD = YORD.

COMMIT WORK.