Count with condition if text='xxx'

edited 8:28AM in FastReport 3.0
i'm new try fr,
i have data like this,

period ket
1 libur
2 libur
3 libur
4 kerja
5 kerja
6 libur

how can i get count of "ket" for libur = 4, keja = 2 in footer

thanks

Comments

  • ShivanShivan Germany
    edited 8:28AM
    Hi,

    I think you have to do this either via SQL or via scripting.

    In script you have to create a variable/stringlist for example and there count your values.
    If mystringlist.names.indexof('..') = -1 then add a new row
    else increase your count by increasing mystringlist.values[yourindex]

Leave a Comment