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
TommyHerman
Frequent Visitor

New table with averages per month that filter other table

Hi!

 

I'm trying to create at table based of another table that calculates the average of a column per month that also filters out based on 2 other columns.

My data (this data will be expanded to contain data from way in the past and also new data from months to come)

Data.jpg

 

I would like to create a new table or at least a way to present the average of column [SL 20] by month that is filtered if column [Antal besvarade samtal] or [Tappade samtal] is higher than 0.

My initial tought was to create a calculated table with columns for month and the sum of values in [SL 20] divided by number of rows that are higher than 0 in [Antal besvarade samtal] or [Tappade samtal].

 

To clarify (example data), the resulting table.

Output.jpg

 

Hopefully someone can help me with this. Or maybe have a better way of accomplishing this.

 

Best regards,

Tommy Herman

 

1 ACCEPTED SOLUTION
v-chuncz-msft
Community Support
Community Support

@TommyHerman,

 

You may simply try AVERAGEX and FILTER to add a measure.

Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
v-chuncz-msft
Community Support
Community Support

@TommyHerman,

 

You may simply try AVERAGEX and FILTER to add a measure.

Community Support Team _ Sam Zha
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Thank you @v-chuncz-msft!

 

With your help I managed to get it working with this folmula, 

= CALCULATE(AVERAGEX(Samtalsstatistik, Samtalsstatistik[SL 20]), FILTER(Samtalsstatistik, OR(Samtalsstatistik[Antal besvarade samtal] > 0, Samtalsstatistik[Tappade samtal] > 0)))
 
Regards,
Tommy Herman

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.