Skip to Content
Former Member
May 11, 2009 at 07:17 PM

ALV GRID: Count values in Totals row.


Hi gurus,

I have an ALV GRID and I have this requeriment:

"In Totals row, there must be the numbers of rows where the field FLAG is set to 'X''.

I'm calling the totals row with IT_SORT parameter in 'REUSE_ALV_GRID_DISPLAY' and setting the attribute DO_SUM in the fieldcat for the fields I need to sumarize; but I need to count how many rows have value 'X'.

How can I do this? Some ideas?

An Example of what I need:

Col.A | Col.B

1000 | X

2000 |

3000 | X


6000 | 2 <- TOTALS ROW

A lot of thanks.

Edited by: Ole ES on May 11, 2009 9:18 PM