Friday, June 21, 2013
  • Go to SE11 and enter table name(eg. ZTEST) ->Display
  • Click UTILITIES menu->Table Maintenance Generator 
  • Click on ENVIRONMENT menu->Modification->Maintenance screens->Double click on record in the popup.
  • Write one MODULE SORT_EXTRACT to sort exactly before Table Control loop statement(LOOP AT EXTRACT WITH CONTROL)
  • Write the below piece of code at SORT_EXTRACT to sort Table Maintenance.
    MODULE SORT_EXTRACT OUTPUT.
      DATA : IT_ZTEST LIKE ZTEST OCCURS 1 WITH HEADER LINE .
      IF NOT SY-UCOMM = 'NEWL'.
        IT_ZTEST[] = EXTRACT[].
        SORT IT_ZTEST BY F1 F2 F3.
        EXTRACT[] = IT_ZTEST[].
      ENDIF.
    ENDMODULE.                 " SORT_EXTRACT  OUTPUT

2 comments:

  1. Hi there,
    when trying to activate the module (which is located in the generated top include of the function group) the error "EXACT" expected, not "EXTRACT[]" occurs.
    Where did you put your module implementation, so that "extract" is known?
    Best regards,
    Peter

    ReplyDelete
  2. DATA : lit_sort like ZTMM_WFDOA occurs 1 WITH HEADER LINE.
    lit_sort[] = extract[].
    SORT lit_sort BY lastname.
    extract[] = lit_sort[].

    getting dump when this statement triggers lit_sort[] = extract[].
    not compatible

    ReplyDelete

Your useful comments, suggestions are appreciated.Your comments are moderated.

Followers

Contact Form

Name

Email *

Message *

Web Dynpro ABAP Book

An SAP Consultant

Follow US


Want to Contribute ?

If you are interested in writing about the new stuff you learn everyday while working, please write to the.sap.consultants@gmail.com.

Click on Contribution for more details.