Skip to end of metadata
Go to start of metadata

Author: http://scn.sap.com/people/sravya.talanki2
Submitted: <date>
Related Links

Description

Source code for the IDOC Error Segment Detail ALV Report that is a bit  more friendlier than WE02 and less technical to the business users.
It  allows the business user to filter the IDOCS based on the IDOC segment  values and allows him to choose the IDOC segment fields that
 he is  interested to view in ALV output in one screen. It eliminates the need  for the business team to drill down IDOC further to
identify the IDOC  data content.The tool will help them to resolve the data errors more  quickly than before. Please refer  the blogs to
deploy the tool in your landscape.

*&---------------------------------------------------------------------*
*& Report  ZIDOC_DETAIL_REPORT
*&
*&---------------------------------------------------------------------*
*&
*&
*&---------------------------------------------------------------------*
*------------------------------------------------------------------------------------------
*                    A D M I N I S T R A T I O N
*------------------------------------------------------------------------------------------
* Author                         : Sravya Talanki
* Created On                     : 22.11.2012
* Description                    : The program is required for reading idoc segments
*                                  and providing the report in XCEL Or ALV Grid
*--------------------------------------------------------------------------------------------
*                    C H A N G E  H I S T O R Y
*--------------------------------------------------------------------------------------------
* Change Id   :
* Author      :
* Changed On  :
* Description :
*
*--------------------------------------------------------------------------------------------

REPORT  zidoc_detail_report LINE-SIZE 400.
TABLES: edids,sscrfields.

"Selection Screen
SELECTION-SCREEN BEGIN OF BLOCK blk WITH FRAME TITLE text-001.
SELECT-OPTIONS:  s_docnum       FOR    edids-docnum OBLIGATORY.
SELECT-OPTIONS:  s_stat         FOR    edids-status OBLIGATORY.
SELECT-OPTIONS:  s_crdat        FOR    edids-credat.
SELECTION-SCREEN END OF BLOCK blk.
SELECTION-SCREEN BEGIN OF BLOCK blk1 WITH FRAME TITLE text-002.
PARAMETERS       p_idct         TYPE   ledid_idoctype DEFAULT 'MBGMCR03'.
PARAMETERS       p_empt         AS     CHECKBOX DEFAULT ' '.
SELECTION-SCREEN SKIP 1.
SELECTION-SCREEN:
          PUSHBUTTON /1(30) button USER-COMMAND alv.
SELECTION-SCREEN END OF BLOCK blk1.

"Data Declaration
DATA gr_idoc_rep TYPE REF TO zcl_idoc_detail_report.

AT SELECTION-SCREEN.
  "Triggered when the user presses the push button
  CASE sscrfields.

    WHEN 'ALV'.
      CALL METHOD gr_idoc_rep->read_idoc_metadata
        EXPORTING
          iv_idoctype = p_idct.

  ENDCASE.

INITIALIZATION.
  button = text-003.
  CREATE OBJECT gr_idoc_rep.

START-OF-SELECTION.
  " Read the Idocs as per the selection criteria and display them in ALV list
  CALL METHOD gr_idoc_rep->read_idoc_data
    EXPORTING
      it_idocnum = s_docnum[]
      it_status  = s_stat[]
      it_crdat   = s_crdat[]
      iv_empty   = p_empt.

  • No labels