SAP Reports / Programs | Logistics - General | Logistics Basic Data | Material Master(LO-MD-MM) SAP LO

MMREO020N SAP ABAP Report - Batch stocks and special stocks: Write program







MMREO020N is a standard Executable ABAP Report available within your SAP system (depending on your version and release level). It is used for You can use this program to archive and delete the following stock records: Batch stock records Consignment stock records Other special stock records The system checks the relevant tables for all of the selected materials...see full standard documentation available for this report. Also check out the submitted Comments related to this SAP report and the details below to see which OBJECTS it interacts with such as TABLES, FUNCTION MODULES, INCLUDES ETC.

If you would like to execute this report or see the full code listing simply enter MMREO020N into the relevant SAP transactions such as SE38 or SE80


ABAP code to call this SAP report using the submit statement

This report can be called from another progam/report simply by using the ABAP SUBMIT statement, see below for example ABAP code snipts of how to do this.






SUBMIT MMREO020N. "Basic submit
SUBMIT MMREO020N AND RETURN. "Return to original report after report execution complete
SUBMIT MMREO020N VIA SELECTION-SCREEN. "Display selection screen of submitted report to user
    See more syntax options for the ABAP SUBMIT statement


Text pool values


Selection Text: WERKS = D .
Selection Text: P_WRITST = D .
Selection Text: P_WRIPRD = D .
Selection Text: P_SNAP = D .
Selection Text: P_PROT_O = D .
Selection Text: P_PROT = D .
Selection Text: P_DEST = D .
Selection Text: P_DELTST = D .
Selection Text: P_COMENT = D .
Selection Text: P_AR_ILM = D .
Selection Text: MILL_RTI = D .
Selection Text: MATNR = D .
Selection Text: T_REST = Check expiration date
Selection Text: S_BATCH = Delete only stock recs w/o stk
Selection Text: SP_STOCK = Special Stocks
Selection Text: D_CONSI = Ignore consignment del. flag
Selection Text: D_BATCH = Ignore batch deletion flag
Selection Text: CONSIGN = Consignment
Selection Text: CHARG = Batch Number
Selection Text: BATCHES = Batches
Title: Batch stocks and special stocks: Write program
Text Symbol: N02 = Retention Duration reached
Text Symbol: N01 = Snapshot archived
Text Symbol: 521 = Only consider batch stock records without stock
Text Symbol: 519 = Restrictions
Text Symbol: 518 = Options
Text Symbol: 516 = Materials
Text Symbol: 027 = Retention period orig. batch
Text Symbol: 026 = Check expiration data of batches
Text Symbol: 025 = Batch Number
Text Symbol: 024 = Other special stocks
Text Symbol: 023 = Consider consignment record without deletion flag
Text Symbol: 022 = Consignment
Text Symbol: 021 = Consider batch record without deletion flag
Text Symbol: 020 = Batches
Text Symbol: 002 = &2 of &3 of the selected objects (&1%) processed
Text Symbol: 001 = Start of Data Processing


INCLUDES used within this REPORT MMREO020N

INCLUDE MMREO028.




INCLUDE MMREO003.
INCLUDE MMREO02TN.


TABLES used within REPORT and the associated SELECT statement:

No SAP DATABASE tables are accessed within this REPORT code!


Function Modules used within report and the associated call statement:

ARCHIVE_GET_INFORMATION call function 'ARCHIVE_GET_INFORMATION' exporting archive_handle = arch_handle importing object_number_in_file = tab_counter2 exceptions internal_error = 1 wrong_access_to_archive = 2 others = 3.

PROGRESS_INDICATOR call function 'PROGRESS_INDICATOR' exporting i_text = text-001 i_output_immediately = 'X'.

DB_COMMIT call function 'DB_COMMIT'.

PROGRESS_INDICATOR call function 'PROGRESS_INDICATOR' exporting i_text = text-002 i_msgv2 = tabix_read i_msgv3 = tab_counter2 i_processed = tabix_read i_total = tab_counter2 i_output_immediately = lv_output_immediately importing e_progress_sent = lv_message_sent.

DB_COMMIT call function 'DB_COMMIT'.

PROGRESS_INDICATOR call function 'PROGRESS_INDICATOR' exporting i_text = text-002 i_msgv2 = tabix_read i_msgv3 = tab_counter2 i_processed = tabix_read i_total = tab_counter2 i_output_immediately = lv_output_immediately importing e_progress_sent = lv_message_sent.

DB_COMMIT call function 'DB_COMMIT'.



Contribute (Add Comments)

Although this basic information may have limited use it does provide an easy to find location to store any knowledge about this program/report.







The contribute/comments section below therefore offer's an opportunity for anyone to add additional information. This can be anything from useful hints, tips and screen shots to relevant SAP notes or anything else you feel is relevant to this report.

This will then be available for everyone to easily find by simply searching on the report name MMREO020N or its description.