ALV Standard Sum Totall

You might also like

Download as pdf
Download as pdf
You are on page 1of 3
‘sa20%4 ALY Standard Sum Total Or Subolal- ABAP Dowlopmont- SCN Wk nes ot usionss Univers Aianees Evens Webinars Imowton ALV Standard Sum Total Or Subtotal san ALVfaton mot REE ALY GRO, SALA REUSE ALV_LET. PLAY hy rte td tinal una or usualy, Te pape aig hot +. Tosumtta so wna you strate aletgny. nie sre of aaa, eis companies hon setae ag PUES ALV_GRO_OSPAY o RELSE ALV LET BSAA, Pt llpy te sume ls eta lo cgay to vae Xone eh annem ay trstincton, When yu ne et ab, you thou pant ce etre elo a we. The a ponte whe es epee osu, ert Yu sho poo wen fala sptoa sure, Issa esata ian yu sta eens, gotta ane ange va bs. REPORT 2yh_alv_subtotal_extra_line TPE-Po0LS sis sees: BEGIN OF ty_Flight, careid TOE sflight-carrta, connid TWEE sflight-connid, Aidate TYEE sflight-flaate, seatsnax IVPE sflight-sestenax, seatsoce IVPE sflight-seatsocc, ENO OF ty_flight. ‘ty_flight_tab TYPE STANDARD TABLE OF ty_#Lieht. At fight IVE ty_f2ight_tab: SSTART-OF SELECTION. PERFORM sub_alv_display. ‘8 Form sub_alv_display ‘ Display alv FoR sub_alv_display. I layout TYPE slis_layout_alv, — Li_sort TYPE slis_t sortinfo_alv, Iu_sort TYPE sléssortinfo_alv. PERFORM sub_got_data, PERFORM sub_fora_Fieldeat CHANGING 14_fLeldeat. PERFORM sub_sort CHANGING 1i_sort List display is different fron grid display. List display is just displaying total or subtotal, but grid display besides display it also provide the extension. Meanwhile in grid display, sf sorting and the several Line Gisplay, only display one value phi: son sap comWikleisplayABAPIALV Standard+-Sum+Total+Or+ Subtotal 18 aa014 ALY Standard Sum Total Or Subolal- ABAP Dowlopmont- SCN Wk + LeaLtaack_progean sy-repia + tayour = Iw Layout + rr ptetoear = Woeldcat + rrsoRr = 1ilsore + teuttay = te pligne + others =2 + IF sy-subre © 0 i_callback_progran = sy-repid 15 layout = Iw tayout itlsort = li_sert "can sum sub total outta = ss flight EXCEPTIONS progranerron = 1 OTHERS 2 TF sy-subre © 6 NESSAGE 10 sy-nsgid TYPE sy-nsgty NUMBER sy-nsgno WITH sy-msgvi sy-nsgv2 sy-nsgv3 sy-nsgvé. ENoFORM. sub_alv_ display *h Form sub_get_data Fo sub_got_data, SELECT carrid connia nd FROM sFLSahe WTO TABLE 1t_#2ight EnoFonu, sub_get_daca te - sh Form sub form fieldcat . Define Fieldcategory FoR sub_fora_fleldcat CHINGING pi_fieldcat TVPE slis_t_fleldcat_alv. Im fieldcat TWPE slis_fieldcat_alv. Im fieldcat-Fieldnane = “CARRIO: APPEND Im_fieldcat TO pi_fieldcat. CLEAR lw Fielacst. 1m fleldcat-Fielénane = ‘ConNI0". Iw fieldcat-seltext_l = “CONNID". APPEND Iw_fleldcat TO pi_fielacat. pik: son sap comWikleisplayABAPIALV Standard+- Sum Total Or+ Subtotal 28 aa014 ALY Standard Sum Total Or Subolal- ABAP Dowlopmont- SCN Wk In_fleldcat-seltext_l = 'FLOATE’ apPeND Iw_fleldcat TO pi_fielacat. CLEAR Iw Faeldcst. Im_fieldcat-Fieldnane = “SEATSHAX’. In fieldcat-seltext_l = ‘SEATSHAX CLEAR Iu #ieldeat . 1Im_fieldcat-fielénane = 'SEATSOCC’ In fieldcat-seltext_1 = "SEATSOCC". + Field de_sum means this field do total sum apPeND I Fleldcat TO pi_fieldcat. CLEAR Iw Faelacst. ENOFORM. ‘sub_fors_fieldcat ‘ Sorting and point out sub total FOR sub_sort CHANGING pi_sort TYPE s1is_t_sortinto_alv. Iw_sort TYPE s14s_sortinfo_atv. Iw_sort-fleldnane = ‘CARRIO". “sort depending on which fsel6 Iu_sort-up = 'X', "ascending sequence APPEND Iw_sort TO pi_sort. CLEAR Iw_sort: Iw_sort-Fieldnane = ‘CONNTD', “sort depending on which Field ln_sort-subtot = °X', "sub calculate depending on this fiele Iw_sort-up sending sequence APPEND Iw_sort TO pi_sor ENOFORM. sub_sort 2.Comments pik: son sap comWikleisplayABAPIALV Standard+- Sum Total Or+ Subtotal a

You might also like