cancel
Showing results for
Did you mean:

The ultimate Microsoft Fabric, Power BI, Azure AI & SQL learning event! Join us in Las Vegas from March 26-28, 2024. Use code MSCUST for a \$100 discount. Register Now

Post Prodigy

## Filter measure in Power BI

Hi,

I would like to filter measure according to another measure condition. For example, calculate(a, filter(b<30).

But problem is that new column becomes same as old. I don't get why it happens.

For example,

Measure equals to Bendra skola even Measure contains blank values, so how to fix my measure to calculate correctly.

5 REPLIES 5
Resolver IV

Hi @Analitika ,

Can you just change the measure like below,

Filtered measure =
SUMX (
FILTER (
AllSelected( 'DBA klient_tiekejai'),
),
CALCULATE ( [_m_ST_Bendra_Skola] )
)

Please Accept it as a solution if it solves your problem. Thanks.

Super User

When the calculation is performed at the grand total level then the filter condition is met. You need to iterate over whichever column provides a unique identifier for the row in your table, e.g. if the rows each show a different date then you could use

``````Filtered measure =
SUMX (
VALUES ( 'Date'[Date] ),
CALCULATE ( [A], FILTER ( 'Table', [B] < 30 ) )
)
``````

Post Prodigy

I tried but it didn't change at all:

Filtered measure =
SUMX (
VALUES ( 'DBA klient_tiekejai'[kli_pav] ),
CALCULATE ( [_m_ST_Bendra_Skola], FILTER ( '_Measures_ST_PS', [DATA PRADELSIMAS_ST] <= 30 ) )
)

Super User

Try

``````Filtered measure =
SUMX (
FILTER (
VALUES ( 'DBA klient_tiekejai'[kli_pav] ),
),
CALCULATE ( [_m_ST_Bendra_Skola] )
)
``````
Post Prodigy

I have inserted that measure but my visual can't load,  memory exceeded. Getting this:

Announcements

#### Microsoft Fabric Community Conference

Join us at our first-ever Microsoft Fabric Community Conference, March 26-28, 2024 in Las Vegas with 100+ sessions by community experts and Microsoft engineering.

#### Power BI Monthly Update - February 2024

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

#### Microsoft Fabric Career Hub

Explore career paths and learn resources in Fabric.

#### Microsoft Fabric Partner Community

Engage with the Fabric engineering team, hear of product updates, business opportunities, and resources in the Fabric Partner Community.

Top Solution Authors
Top Kudoed Authors