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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
JMac_WandB
Frequent Visitor

apply filter to temporary table in measure

Hi Team,

 

I'm hoping that there is a simple solution to this. I have a table of calculated measures. Put simply I need to count the number of rows where one measure (e.g. the up benchmark) is > 100%. I have tried a number of different approaches (addcollumns + summarizecolumns) but the result is returning all rows (128) rather than the filtered outcome?

 

Can anyone suggest where I may be going wrong here?

Appreciate any help!

 

Up_Cnt4 =
VAR _tmptable =
SUMMARIZECOLUMNS(LIC_Price_NTA[Cal_Period],
"Up", [Up_Returns_Benchmark])

RETURN
CALCULATE(COUNTROWS(_tmptable), FILTER( _tmptable, [Up] > 1))

 

pbi_issue2.jpg

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@JMac_WandB , Try a measure like

Countx(filter(ADDCOLUMNS( Summarize(LIC_Price_NTA[Cal_Period]) ,"Up", [Up_Returns_Benchmark]), [_1] >1), [Cal_Period])

 

 

If this does not help
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@JMac_WandB , Try a measure like

Countx(filter(ADDCOLUMNS( Summarize(LIC_Price_NTA[Cal_Period]) ,"Up", [Up_Returns_Benchmark]), [_1] >1), [Cal_Period])

 

 

If this does not help
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Thanks Amit, perfect (just needed to alter the [_1] to [up])

Really appreciate your quick response.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

Check out the August 2025 Power BI update to learn about new features.

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors