Forum Discussion
why the average function is not working , both the average function on visualization and Dax
Hi clarafff, if you look closely on the selected table, you'll notice the header of the first column "First YEAR_MONTH". If this name has been created automatically there might be an issue with a column data type. "First" means that PowerBI is selecting the first available row with value "2023_05" within column "YEAR_MONTH", therefore the whole table has only 1 row. So your average is correct, as denominator of calcualation is 1. I can't tell you why SUM is working, as I need to see its DAX code before.
Try to replace "First YEAR_MONTH", for example, to "Country". If the average works, you indentified where the issue is (column "YEAR_MONTH").
If wrtitten above is not a case, pay a close attention to filteter context of your visual: make sure that this context is indeed what you expect (I suggest you to filter all columns one by one accordingly in Data tab to ensure that the final filtered table is the one you expect to apply Average formula on).
Hope it helps!
Hi Sergii24,
I have tried many ways, but I'm still not be able to find the probelm . Could you please help me check what is wrong with my file?Active users.pbix - Google Drive