Forum Discussion

LeeFord's avatar
LeeFord
Regular Visitor
8 years ago
Solved

Count values between two time stamps

Hi,

 

I effectively have phone call records that have a start and end time on them. Is there anyway to calculate how many calls were active at the same time along a line chart? (If I select the start or end time as the axis, unless more than one record has the exact same timestamp its a straight line.)

 

Thanks

Lee

  • Hi LeeFord,

     

    You can create a measure and using DAX formula below:

    CALCULATE (
        COUNT ( table[calls] ),
        FILTER (
            table,
            table[time] <= MAX ( table[time] )
                && table[time] >= MIN ( table[time] )
        )
    )

    Regards,

    Jimmy Tao

1 Reply

  • v-yuta-msft's avatar
    v-yuta-msft
    Community Support

    Hi LeeFord,

     

    You can create a measure and using DAX formula below:

    CALCULATE (
        COUNT ( table[calls] ),
        FILTER (
            table,
            table[time] <= MAX ( table[time] )
                && table[time] >= MIN ( table[time] )
        )
    )

    Regards,

    Jimmy Tao