2 Replies Latest reply: May 12, 2010 9:07 PM by John Witherspoon RSS

    Trouble with getting average over selected months

      Hi

      I am still fairly new to Qlikview so hopefully I can articulate my question. Currently I am displaying a field that has this

      count(distinct Member)

      And this will display the unique member count over the selected period of time (the selection is always in whole months). What I would like to display is the average number of members per month or:

      (count(distinct (Members for first month selected)) + count(distinct (Members for the second month selected)) +.......+ count( distinct (Members for the Last month selected)))/ count(distinct [Submit MonthStart Dt]))

      The denominator I know how to do and that will display the month count for me. The Numerator is the part I am having a problem with. I am trying to make it so no matter how many months are selected the same piece of code will work. Does anyone know a way I can do this?

       

      Thank you for looking at my issue,

      Jon