SAP ABAP Reports and Programs

Share |

SAPF080 SAP Report - Mass Reversal of Documents

SAPF080 is a standard ABAP report available within your SAP system (depending on your version and release level). Below is the standard documentation available for this report and a few details of other objects it interacts with such as tables, function modules, includes etc. If you would like to see the full code listing simply enter SAPF080 into the relevant SAP transaction such as SE38 or SE80

Although this basic information may have limited use other that for reference, within the comments section below there is also an opportunity for anyone to add useful hints, information and links to existing content specific to this abap report. This page will therfore over time start to contain a useful amount of information that can be found quickly, simply by searching on the object name, SAPF080.


SAP Documentation for program SAPF080

Transaction Code:

N/A

DESCRIPTION
Program SAPF080 reverses accounting documents (function generalization Document -> Reverse).
On the selection screen, you can select the documents which you want to reverse. If you do not make an entry in the program parameter "Reverse document posting date" or "Reverse document posting period", the system uses today's date or the current posting period.
The program can be carried out in either the test or production run (compare "Production run" program parameter).

OUTPUT
The program generates a list which you can print out, of all the documents which can or cannot be reversed or have already been reversed. In the test run, all the documents in this list which can be reversed, are reversed using the Reverse documents function.
Documentation extract taken from SAP system, Copyright (c) SAP AG

Includes used within report:

INCLUDE RKASMAWF. "NOTE1178245
INCLUDE SCHEDMAN_EVENTS. " EVENTS FOR WORKFLOW
INCLUDE SCHEDMAN_EVENTS.


Tables used within report and the associated select statement:

T100 SELECT SINGLE * FROM T100 WHERE SPRSL = SY-LANGU AND ARBGB = P_MSGID AND MSGNR = P_MSGNO.

BVOR SELECT * FROM BVOR WHERE BVORG = XBKPF-BVORG AND ( BUKRS NE XBKPF-BUKRS OR BELNR NE XBKPF-BELNR OR GJAHR NE XBKPF-GJAHR ).

BKPF SELECT SINGLE * FROM BKPF WHERE BUKRS = BVOR-BUKRS AND BELNR = BVOR-BELNR AND GJAHR = BVOR-GJAHR.

BSEG SELECT * FROM BSEG WHERE BUKRS = XBKPF2-BUKRS AND BELNR = XBKPF2-BELNR AND GJAHR = XBKPF2-GJAHR.


Function Modules used within report and the associated call statement:

FM00_CHECK_JFMIP_MODE *(del) CALL FUNCTION 'FM00_CHECK_JFMIP_MODE' "Note1236143 *(del) IMPORTING "Note1236143 *(del) E_JFMIP_MODE_ACTIVE = JFM_MODE. "Note1236143

FM00_CHECK_ISPS CALL FUNCTION 'FM00_CHECK_ISPS' "Note1236143 IMPORTING "Note1236143 e_ps_us_active = jfm_mode. "Note1236143

SSC_SR_MANUAL_REGISTER CALL FUNCTION 'SSC_SR_MANUAL_REGISTER' EXPORTING iv_scenario = 'FINANCIALS' iv_element = lv_trcode iv_callback = 'FIN_FSSC_APPL_SRC_SAPMF05R'.

SAPGUI_PROGRESS_INDICATOR CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR' "Note1487636 EXPORTING "Note1487636 PERCENTAGE = '50' "Note1487636 TEXT = TEXT-036. "Note1487636

SAPGUI_PROGRESS_INDICATOR *(del) CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR' "Note1487636 *(del) EXPORTING "Note1487636 *(del) PERCENTAGE = '50' "Note1487636 *(del) TEXT = TEXT-036. "Note1487636

POPUP_NO_LIST CALL FUNCTION 'POPUP_NO_LIST' EXPORTING ON_EMPTY_LIST = SPACE FORCE = 'X'.

SAPGUI_PROGRESS_INDICATOR CALL FUNCTION 'SAPGUI_PROGRESS_INDICATOR' EXPORTING PERCENTAGE = '50' TEXT = TEXT-035.

BAL_LOG_CREATE CALL FUNCTION 'BAL_LOG_CREATE' EXPORTING I_S_LOG = XS_LOG IMPORTING E_LOG_HANDLE = ES_LOG_HANDLE EXCEPTIONS LOG_HEADER_INCONSISTENT = 1 OTHERS = 2.

REUSE_ALV_LIST_DISPLAY * CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY' * EXPORTING * I_CALLBACK_PROGRAM = IV_REPID * I_CALLBACK_PF_STATUS_SET = GC_FORM_PF_STATUS * I_CALLBACK_USER_COMMAND = GC_FORM_USER_COMMAND * IS_LAYOUT = LS_LAYOUT * IT_FIELDCAT = LT_FIELDCAT * I_SAVE = GC_VALUE_A * IS_VARIANT = IS_VARIANT * IT_EVENTS = LT_EVENTS * IS_PRINT = LS_PRNT_GLOBAL * IT_SORT = LT_SORT_ACC * TABLES * T_OUTTAB = IT_SUCESS * EXCEPTIONS * PROGRAM_ERROR = 1 * OTHERS = 2.

REUSE_ALV_FIELDCATALOG_MERGE * CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE' * EXPORTING * I_STRUCTURE_NAME = GC_STRUC * CHANGING * CT_FIELDCAT = XT_FIELDCAT * EXCEPTIONS * INCONSISTENT_INTERFACE = 1 * PROGRAM_ERROR = 2 * OTHERS = 3.

REUSE_ALV_EVENTS_GET * CALL FUNCTION 'REUSE_ALV_EVENTS_GET' * EXPORTING * I_LIST_TYPE = 0 * IMPORTING * ET_EVENTS = XT_EVENTS * EXCEPTIONS * LIST_TYPE_WRONG = 1 * OTHERS = 2.

REUSE_ALV_LIST_LAYOUT_INFO_GET CALL FUNCTION 'REUSE_ALV_LIST_LAYOUT_INFO_GET' IMPORTING E_WIDTH = LV_WIDTH EXCEPTIONS NO_INFOS = 1 PROGRAM_ERROR = 2 OTHERS = 3.

FAGL_BATCH_HEADING_PERFORM CALL FUNCTION 'FAGL_BATCH_HEADING_PERFORM' EXPORTING IS_BHDGD = BHDGD.

BAL_DSP_PROFILE_NO_TREE_GET CALL FUNCTION 'BAL_DSP_PROFILE_NO_TREE_GET' "No Tree in App Log IMPORTING E_S_DISPLAY_PROFILE = GS_DISPLAY_PROFILE EXCEPTIONS OTHERS = 1.

BAL_DSP_LOG_DISPLAY CALL FUNCTION 'BAL_DSP_LOG_DISPLAY' EXPORTING I_S_DISPLAY_PROFILE = GS_DISPLAY_PROFILE EXCEPTIONS OTHERS = 1.

BAL_LOG_MSG_ADD CALL FUNCTION 'BAL_LOG_MSG_ADD' EXPORTING I_LOG_HANDLE = IS_LOG_HANDLE I_S_MSG = LS_MESSAGE EXCEPTIONS LOG_NOT_FOUND = 1 MSG_INCONSISTENT = 2 LOG_IS_FULL = 3 OTHERS = 4.

BAL_DSP_LOG_PRINT CALL FUNCTION 'BAL_DSP_LOG_PRINT' EXPORTING I_S_LIST_APPEND = GC_CHECKED I_S_DISPLAY_PROFILE = GS_DISPLAY_PROFILE I_T_LOG_HANDLE = LT_LOG_HDL EXCEPTIONS PROFILE_INCONSISTENT = 1 INTERNAL_ERROR = 2 NO_DATA_AVAILABLE = 3 NO_AUTHORITY = 4 OTHERS = 5.

REUSE_ALV_LIST_DISPLAY CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY' EXPORTING I_CALLBACK_PROGRAM = GV_REPID IS_LAYOUT = LS_LAYOUT IT_FIELDCAT = LT_FIELDCAT I_SAVE = GC_SAVE IT_EVENTS = LT_EVENTS IS_PRINT = LS_PRNT_GLOBAL TABLES T_OUTTAB = GT_NCC_SUCCESS EXCEPTIONS PROGRAM_ERROR = 1 OTHERS = 2.

REUSE_ALV_FIELDCATALOG_MERGE CALL FUNCTION 'REUSE_ALV_FIELDCATALOG_MERGE' EXPORTING I_PROGRAM_NAME = GV_REPID I_STRUCTURE_NAME = IV_STRUCTURE I_INTERNAL_TABNAME = IV_TABLE CHANGING CT_FIELDCAT = XT_FIELDCAT EXCEPTIONS INCONSISTENT_INTERFACE = 1 PROGRAM_ERROR = 2 OTHERS = 3.

REUSE_ALV_EVENTS_GET CALL FUNCTION 'REUSE_ALV_EVENTS_GET' EXPORTING I_LIST_TYPE = 0 IMPORTING ET_EVENTS = XT_EVENTS EXCEPTIONS LIST_TYPE_WRONG = 1 OTHERS = 2.

REUSE_ALV_COMMENTARY_WRITE CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE' EXPORTING IT_LIST_COMMENTARY = GT_END_OF_LIST.

REUSE_ALV_LIST_DISPLAY CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY' EXPORTING I_CALLBACK_PROGRAM = GV_REPID IS_LAYOUT = LS_LAYOUT IT_FIELDCAT = LT_FIELDCAT I_SAVE = GC_SAVE IT_EVENTS = LT_EVENTS IS_PRINT = LS_PRNT_GLOBAL TABLES T_OUTTAB = GT_NCC_ERRORS EXCEPTIONS PROGRAM_ERROR = 1 OTHERS = 2.

REUSE_ALV_COMMENTARY_WRITE CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE' EXPORTING IT_LIST_COMMENTARY = GT_END_OF_LIST.

REUSE_ALV_LIST_DISPLAY CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY' EXPORTING I_CALLBACK_PROGRAM = GV_REPID IS_LAYOUT = LS_LAYOUT IT_FIELDCAT = LT_FIELDCAT I_SAVE = GC_SAVE IT_EVENTS = LT_EVENTS IS_PRINT = LS_PRNT_GLOBAL TABLES T_OUTTAB = GT_CC_SUCCESS EXCEPTIONS PROGRAM_ERROR = 1 OTHERS = 2.

REUSE_ALV_COMMENTARY_WRITE CALL FUNCTION 'REUSE_ALV_COMMENTARY_WRITE' EXPORTING IT_LIST_COMMENTARY = GT_END_OF_LIST.

REUSE_ALV_LIST_DISPLAY CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY' EXPORTING I_CALLBACK_PROGRAM = GV_REPID IS_LAYOUT = LS_LAYOUT IT_FIELDCAT = LT_FIELDCAT I_SAVE = GC_SAVE IT_EVENTS = LT_EVENTS IS_PRINT = LS_PRNT_GLOBAL * I_SUPPRESS_EMPTY_DATA = 'X'
TABLES T_OUTTAB = GT_CC_ERRORS EXCEPTIONS PROGRAM_ERROR = 1 OTHERS = 2.

DEQUEUE_EFBKPF CALL FUNCTION 'DEQUEUE_EFBKPF' EXPORTING BELNR = XBKPF2-BELNR BUKRS = XBKPF2-BUKRS GJAHR = XBKPF2-GJAHR.

ENQUEUE_EFBKPF CALL FUNCTION 'ENQUEUE_EFBKPF' EXPORTING BELNR = XBKPF2-BELNR BUKRS = XBKPF2-BUKRS GJAHR = XBKPF2-GJAHR EXCEPTIONS FOREIGN_LOCK = 1 SYSTEM_FAILURE = 2.

DEQUEUE_EFBKPF CALL FUNCTION 'DEQUEUE_EFBKPF' EXPORTING BELNR = XBKPF2-BELNR BUKRS = XBKPF2-BUKRS GJAHR = XBKPF2-GJAHR.

DEQUEUE_EFKNB1AS CALL FUNCTION 'DEQUEUE_EFKNB1AS' EXPORTING KUNNR = XBSEG2-KUNNR BUKRS = XBSEG2-BUKRS.

DEQUEUE_EFLFB1AS CALL FUNCTION 'DEQUEUE_EFLFB1AS' EXPORTING LIFNR = XBSEG2-LIFNR BUKRS = XBSEG2-BUKRS.

DEQUEUE_EFSKB1AS CALL FUNCTION 'DEQUEUE_EFSKB1AS' EXPORTING SAKNR = XBSEG2-HKONT BUKRS = XBSEG2-BUKRS.

FUNCTION_EXISTS CALL FUNCTION 'FUNCTION_EXISTS' EXPORTING funcname = 'SCMA_JOB_STARTED_FROM_SCMA' EXCEPTIONS function_not_exist = 1 OTHERS = 2.

SCMA_JOB_STARTED_FROM_SCMA CALL FUNCTION 'SCMA_JOB_STARTED_FROM_SCMA' EXPORTING before_init = 'X' wf_witem = wf_witem IMPORTING e_scma = g_scma.

KPEP_MONI_INIT_RECORD CALL FUNCTION 'KPEP_MONI_INIT_RECORD' EXPORTING ls_detail = ls_detail ls_witem = ls_witem IMPORTING ls_key = gs_key TABLES lt_selkrit = lt_selkrit lt_param = lt_param.

KPEP_MONI_CLOSE_RECORD CALL FUNCTION 'KPEP_MONI_CLOSE_RECORD' EXPORTING ls_key = gs_key ls_scma_event = ls_scma_event CHANGING ld_aplstat = ld_aplstat EXCEPTIONS OTHERS = 1.


Text pool values


Selection Text: TESTLAUF = D .
Selection Text: STODAT = D .
Selection Text: STOBLDAT = D .
Selection Text: MONAT = D .
Selection Text: VATDATE = D .
Selection Text: STOGRD = Reason for reversal
Selection Text: BVOR_YES = Process
Selection Text: BVOR_POS = Relevant docs if possible
Selection Text: BVOR_NO = Do not process
Selection Text: BVOR_ALL = Only reverse completely
Title: Mass Reversal of Documents
Text Symbol: 026 = Can be reversed
Text Symbol: 027 = Cross-Company Code Transaction
Text Symbol: 028 = Cross-company code transactions that can be compl. reversed
Text Symbol: 029 = Cross-company code transacts that cannot be completely reversed
Text Symbol: 030 = Completely reversed cross-company code transactions
Text Symbol: 031 = Cannot be reversed; document from cross-company code trans. cannot be reversd
Text Symbol: 032 = Option selected: Reverse relevant documents if possible
Text Symbol: 033 = Option selected: Only reverse relevant documents if transaction can be completely reversed
Text Symbol: 034 = Processing completed
Text Symbol: 035 = Document is being processed...
Text Symbol: 036 = Document selection is running...
Text Symbol: 037 = Message
Text Symbol: 001 = Docs which cannnot be reversed
Text Symbol: 002 = Docs which can be reversed
Text Symbol: 003 = Reversed documents
Text Symbol: 006 = reversed with document ;;
Text Symbol: 007 = All documents can be reversed.
Text Symbol: 008 = No document can be reversed.
Text Symbol: 009 = All documents were reversed.
Text Symbol: 010 = Mass Reversal of Documents: Initial Screen
Text Symbol: 011 = Test run
Text Symbol: 012 = Upd. run
Text Symbol: 013 = Document number;;
Text Symbol: 014 = Company code ;;
Text Symbol: 015 = Fiscal year ;;
Text Symbol: 016 = Doc.type ;;
Text Symbol: 017 = Posting date ;;
Text Symbol: 018 = Document date ;;
Text Symbol: 019 = Reference document number ;;
Text Symbol: 020 = All items in the document were cleared
Text Symbol: 021 = Further selections
Text Symbol: 022 = Reverse posting details
Text Symbol: 023 = Number of documents reversed:
Text Symbol: 024 = Cross-company code transactions
Text Symbol: 025 = Non-Cross-Company Code Transactions






Terms of Service     Contact Us     Privacy Policy     Useful SAP related sites