首页 > SAP > ODATA > Subtotals in ALV using CL_SALV_TABLE
2019
08-29

Subtotals in ALV using CL_SALV_TABLE

In this tutorial, we will learn how to apply totals and subtotals in ALV report using factory class CL_SALV_TABLE.

To apply Subtotals in ALV,

Apply totals on a column in ALV. click here to know
Apply SORTing on a column ALV to which you want subtotals using method ADD_SORT(). click here
Enable subtotals for the column by passing the parameter while calling the method ADD_SORT().

Classes Used : CL_SALV_TABLE, CL_SALV_AGGREGATIONS and CL_SALV_SORTS.

Create a program in SE38-ABAP编辑器 and copy the below code.

https://gist.github.com/prakash13t/6688ce13ce8eddf42325#file-subtotal_salv-abap

Output with Totals and Subtotals on Airline column:

[adsenseyu1]

Subtotals in ALV using CL_SALV_TABLE - 第1张  | 优通SAP

最后编辑:
作者:yangsen
本站为个人博客网站,全由我个人维护,我从事SAP开发13年,其它ERP开发7年,基本都是零售行业。本站记录工作学习的过程, 有SAP相关询问专、兼职工作可随时联系我。 有网站相关的问题可直接在文章下方留言,或者联系我。 邮件:yan252@163.com给我。 QQ:415402519