Hi Sri Devi ,
Based on mblnr you can the internal table with the help of sorting table
in the field catalog pass as below and sort based on the mblnr
gw_fcat-fieldname = 'KWMENG'.
gw_fcat-tabname = 'GT_FINAL'.
gw_fcat-seltext_m = 'Quantity'.
gw_fcat-do_sum = 'X'. """""This is for sum up the internal Table""""
APPEND gw_fcat TO gt_fcat.
CLEAR gw_fcat.
*&---------------------------------------------------------------------*
*& Form f_display_alv
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
FORM f_display_alv .
DATA:lv_repid TYPE sy-repid.
lv_repid = sy-cprog.
DATA: w_layout TYPE slis_layout_alv.
w_layout-colwidth_optimize = 'X'.
w_layout-zebra = 'X'.
gw_sort-fieldname = 'VBELN'.
gw_sort-tabname = 'GW_FINAL'.
gw_sort-subtot = 'X'.
APPEND gw_sort TO gt_sort.
CALL FUNCTION 'REUSE_ALV_GRID_DISPLAY'
EXPORTING
i_callback_program = sy-cprog
i_callback_user_command = 'USER_COMMAND'
i_callback_top_of_page = 'TOP_OF_PAGE'
is_layout = w_layout
it_fieldcat = gt_fcat
it_sort = gt_sort
TABLES
t_outtab = gt_final.
- ENDFORM. "f_display_alv