Forum Discussion

navenn08's avatar
navenn08
New Member
3 years ago
Solved

DAX ALLSELECTED DISPLAYING BLANKS

Hi All, I'm trying to create an Average for a count distinct on a time series data, using the below formula i managed to create an Average line   AVG_RECEIPTS = CALCULATE(     AVERAGEX(Values...
  • tamerj1's avatar
    3 years ago

    Hi navenn08 
    Please try

    AVG_RECEIPTS =
    IF (
        [TOT_REC] <> BLANK (),
        CALCULATE (
            AVERAGEX (
                VALUES ( 'DATE'[Date] ),
                CALCULATE ( DISTINCTCOUNT ( CO_DLY_sample[CLM_NUMBER] ) )
            ),
            ALLSELECTED ()
        )
    )