Forum Discussion

abukapsoun's avatar
abukapsoun
Post Patron
5 years ago
Solved

Calculate distinct

Hi,

I need your expertise please

 

I have the following table

 

HCPrice
X350
X350
X350
Y400
Y400
Z600
Z600

 

 

How can I compute the average price taking into consideration distinct HCs and not all of them?

 

Thanks,

 

  • abukapsoun - Seems like this should be:

    Measure 29 = 
        VAR __Table = SUMMARIZE('Table (29)',[HC],"Average",AVERAGE([Price]))
    RETURN
        AVERAGEX(__Table,[Average])

    Attached PBIX below sig, Page 29.