Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Average count per month

I have a date table.   We have our orders that come in daily, although some days no orders come in.   I need to determine the average number of orders per month.  Using order ID.  so a simple ex...
  • v-easonf-msft's avatar
    6 years ago

    Hi , Anonymous 

    If no orders come in on a certain day of a month and that day will still be counted,you can try measure as below:

    Measure2 = 
    var countRow=CALCULATE(COUNT('Table'[Day of month]),ALL('Table'))
    var days=DAY(EOMONTH(SELECTEDVALUE('Table'[Date]),0))
    return DIVIDE(countRow,days)

    pbix attached

     

    Best Regards,
    Community Support Team _ Eason