Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
PascalCL
Frequent Visitor

Average is not calculated correctly Need Help

Hello I need your help again,

here is the measure for it.

 

Ø / Monat =
ROUNDUP(AVERAGEX(
    VALUES('Date (2)'[Date].[MonthNo]),
        CALCULATE([Verkauft])
    ),0
)

Unbenannt (4).jpg

 

 

 

Unfortunately, he does not calculate it correctly.

As you can see, the filter is set to 6 months.

Thus, the sold items should be calculated by the number of months.

 

As an example:

600PCS/ 6 ( months) = 100PCS

5 REPLIES 5
PascalCL
Frequent Visitor

@lbendlin 

Thanks for your effort but unfortunately this is not what I need.

 

I am already a small step further and know why PB calculates this incorrectly.

Pictures say more than 1000 words

 

 

01.05.2022

01.06.2022

01.07.2022

01.08.2022

01.09.2022

01.07.2022

 

123

50

70

80

45

74

60

63,2

654

 

 

60

 

 

 

60,0

654

0

0

60

0

0

0

10,0

 

Empty cells are ignored in both Excel and PB.

 

Now the question arises can I get around this?

Or would it be feasible if I set the date filter to 6 months that I then get the number 6 as a value.

 

Look at the here please.

https://we.tl/t-H3V6kGw3pm

To report on things that aren't there you need to use cross joins and/or disconnected tables.

lbendlin
Super User
Super User

Please provide sanitized sample data that fully covers your issue.
https://community.powerbi.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-...
Please show the expected outcome based on the sample data you provided.

https://community.powerbi.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523

 @lbendlin as requested the test file with the same problem

https://we.tl/t-QXVLdlIibV

 

Ø / Monat = 
var a = SUMMARIZE('Tabelle1 (2)','Tabelle1 (2)'[Art Nr],'Tabelle1 (2)'[Sale Date].[Month],"s",sum('Tabelle1 (2)'[Quantity]))
return AVERAGEX(a,[s])

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.