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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
matthewL
New Member

Average of a measure

Hi everyone.

 

I'm trying to calculate the average value of the CORRECT_STOCK for all the items I've got in my DB. The problem is that I find it difficult to calculate the average of a measure, without having a column or table.

 

I made two attempts to calculate it, but as you can see the values are not correct (in the first case I get the last value of CORRECT_STOCK for the item, while in the second I get a too low value.

 

Warehouse.pbix 

 

Can you help me? Thank you in advance.

1 ACCEPTED SOLUTION

@matthewL 

 

If you open the workspace that i have attached on the message you will notice that the first field comes from MSTR_ITM table and not FACT_MOVE table.

 

It seems that these 2 tables are not connected properly in the data model.

 

Also in the filter page the page filter comes MSTR_ITM table and not FACT_MOVE table

View solution in original post

3 REPLIES 3
themistoklis
Community Champion
Community Champion

@matthewL 

 

This measure works for me:

Average New = AVERAGEX(VALUES('Calendario RIDOTTO'[Date]),[CORRECT_STK])

 

See attached workspace.

 

 

Sorry but the value is the same for all items (283.85), or am I wrong? However thanks for the help.same.png

@matthewL 

 

If you open the workspace that i have attached on the message you will notice that the first field comes from MSTR_ITM table and not FACT_MOVE table.

 

It seems that these 2 tables are not connected properly in the data model.

 

Also in the filter page the page filter comes MSTR_ITM table and not FACT_MOVE table

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.