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

Get certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now

Reply
nuhasan
Helper IV
Helper IV

Average based on column

Hi all,

 

I have below table. My goal are to show the target but I want to target be average when I filter 1 or 2 attribute.

 

Example 1: I filter process code 310 only and the target should be average of 94.3% & 95.3% = 94.8%

 

Example 2: I filter storage location PD5 only and the target should be averaeg of 55% & 74.3% =64.65%

 

Storage LocationProcess CodeSegmentMachineTarget
EA310WASHI310 EA Machine94.30%
EB310WASHI310 EB Machine95.30%
PD2612EPM Paper612 RB_PAP H.J Machine98.50%
PD2620EPM Paper620 RB_PAP Machine98.50%
PD2630EPM Paper630 BA_PAP Machine98.50%
PD2630EPM Paper630 BB_PAP Machine98.50%
PD2611EPM PP/T611 RA_PP H.J Machine98.00%
PD2630EPM PP/T630 BF_PP Machine98.00%
PD2620EPM Leadframe620 RA_LF Machine92.40%
PD2620EPM Leadframe620 RD_LF Machine92.40%
PD3610EM DC/T610 TB Machine99.30%
PD3610WASHI610 TB Machine98.90%
PD4640WASHI640 CH Machine94.00%
PD4640WASHI640 CD Machine94.00%
PD4640WASHI640 CK Machine94.00%
PD4640WASHI640 CG Machine94.00%
PD4640WASHI640 CC Machine94.00%
PD4640EM DC/T640 CB Machine96.90%
PD4640EM DC/T640 CC Machine96.90%
PD4640DC/T640 CB Machine97.50%
PD4640DC/T640 CC Machine97.50%
PD4640EPM Polyester640 CC Machine97.50%
PD4640SPV640 CB Machine97.50%
PD4640TAPE640 CC Machine97.50%
PD4640TAPE640 CD Machine97.50%
PD4400EM DC/T400 WH Machine96.00%
PD4400DC/T400 WH Machine96.00%
PD4400WASHI400 WK Machine94.00%
PD5620EPM ELP620 RC_ELP Machine55.00%
PD5650EPM ELP650 SA Machine74.30%

 

Regards,

Nuha

1 ACCEPTED SOLUTION
_AAndrade
Super User
Super User

Hi @nuhasan,

I think I've probably misunderstood your question. You probably want to show the same table but with the target changing according to the filter you're using.
If that's the case, I present another solution on page 2 of my pbix.





Did I answer your question? Mark my post as a solution! Kudos are welcome.

Proud to be a Super User!




View solution in original post

4 REPLIES 4
_AAndrade
Super User
Super User

Hi @nuhasan,

The Sheets 1 table is filtering SAP table and not the oposite, so if you're using any filter from SAP table it will not filter target.
To solve the problem you could activate the both side relationship but it's not a good pratice and probably you could have problems in the future.





Did I answer your question? Mark my post as a solution! Kudos are welcome.

Proud to be a Super User!




_AAndrade
Super User
Super User

Hi @nuhasan,

I think I've probably misunderstood your question. You probably want to show the same table but with the target changing according to the filter you're using.
If that's the case, I present another solution on page 2 of my pbix.





Did I answer your question? Mark my post as a solution! Kudos are welcome.

Proud to be a Super User!




_AAndrade
Super User
Super User

Hi @nuhasan,

Use this measure:

Simple AVG = AVERAGE(T_AllData[Target])


The final output:

_AAndrade_0-1716196649085.png_AAndrade_1-1716196660467.png

 





Did I answer your question? Mark my post as a solution! Kudos are welcome.

Proud to be a Super User!




Hi @_AAndrade ,

 

Actually I want the target reflect at another table. Now when I filter the location or month or other attribute, the target keep maintain 94.22% (which is the average of all target and not by filtering)

 

nuhasan_0-1716248937963.png

 

nuhasan_1-1716249038857.png

 

Regards,

Nuha

 

 

Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

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

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

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