12 Replies Latest reply: Jun 3, 2015 7:48 AM by Tom Broens RSS

    amount of events under variable time

      Dear community,

       

      I have a problem in my dashboard I can't work out.

      I have a couple of events from which I have a beginning and an end time. End time - begin time = duration of the event. All of this I load in my load script.

       

      Now in my dashboard I want the user to insert a value into a variable $(DurationMinutes).

       

      Now the part I can't work out:

      I want a formula with which I calculate the number of events with a duration under or equal to $(DurationMinutes).

      I tried this already:

      =count ({<EventDuration = {"<=time(time#($(DurationMinutes),'m'), 'hh:mm:ss')"}>} EventDuration)

      But this isn't working

      When i change it in this:

      =count ({<EventDuration = {"<=$(time(time#($(DurationMinutes),'m'), 'hh:mm:ss'))"}>} EventDuration)

      It looks like he is counting all the events without taking selections in account (so selections won't work).

       

      Can anyone help me with this please?

      Thanks in advance!!