Add additional fields in VA05 report

Example: Add RAN number in VA05 report

Adding fields in Selection screen: 

Use enhancement spot in program "SD_SALES_DOCUMENT_VIEW".

enhancement-point sd_sales_document_view_ep_int1 spots es_sd_sales_document_view .
*$*$-Start: SD_SALES_DOCUMENT_VIEW_EP_INT1---------------$*$*
ENHANCEMENT 1  ZENH.    "active version
selection-screen begin of block sch1 with frame title text-SCH.
select-options:  skannr for vbap-kannr.
selection-screen end of block sch1.
ENDENHANCEMENT.

Selection parameter into select list

  enhancement-point sd_sales_document_view_ep_int2 spots es_sd_sales_document_view .
*$*$-Start: SD_SALES_DOCUMENT_VIEW_EP_INT2--------------$*$*
ENHANCEMENT 2  ZENH.    "active version
*INSERT LINES OF skannr INTO TABLE gs_selcrit-kannr.
  transfer_select_option 'VBAP' 'KANNR' SKANNR.
ENDENHANCEMENT.

Adding field in the output list. 

Implement BADI: "BADI_SDOC_WRAPPER"

Use method "ADAPT_RESULT_COMP"

INSERT VALUE table 'VBAP' field 'KANNR' name 'VABP_KANNR' text 'RAN/MANIFEST' INTO TABLE ct_result_comp.

Check SAP note "1780163"

Comments

  1. Hi,
    Thank you so much for your documantation. But What will we do if we want to 'SUM' field while select data?

    ReplyDelete
  2. after adding the field to ct result comp, only header is visible. fields aren't getting populated

    ReplyDelete
  3. How to add custom fields in va05 Transaction Output in s4 hana

    ReplyDelete

Post a Comment

Popular posts from this blog

Totals table for ACDOCA in S/4 HANA - ACDOCT

Carry out repairs in non-origina system only if they are urgent