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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
krishna0
Helper II
Helper II

Filter as a measure - applying to single item

Hello!

 

I have a problem concerning filters.

krishna0_0-1674730517650.png

As you can see I have a single card, which task is to count items regardless of the filter from the context. I have put all necessary filters into this card as well:

krishna0_1-1674730595721.png

But the last one, I can't come up with, is actually somehow related to disregarded slicer and I need to show items that has values in column "ClosingIteration" empty or equal to SELECTEDVALUE ( Iteration ) as per screenhsots. Iteration is taken from another table and relation looks like this: 

krishna0_2-1674730699220.png

Names are the same, but I struggle to create a measure that will, e.g. be 1 in case of blank/<iteration name> and adding it to the filter pane. I know that filters shows aggregations and the measure should calculate such values per row, but my intuition says that it is possible, thus hard for me to achieve.

 

Any tips?

2 REPLIES 2
krishna0
Helper II
Helper II

Hello, any advices on this topic?

krishna0
Helper II
Helper II

I have even reproduced number of records I want to drill through to (I was thinking about filter because I can't drill from this field):

krishna0_0-1674743061963.png

Measure_1
    =
    VAR _selectedIter =
        SELECTEDVALUE ( IterDates[IterationLevel2] )
    VAR _StartDate =
        CALCULATE (
            MAX ( IterationToDate[DateOnly] ),
            FILTER (
                ALL ( IterationToDate ),
                IterationToDate[CorrectStartIter] = SELECTEDVALUE ( IterDates[IterationLevel2] )
            )
        )
    VAR _checker =
        CALCULATE (
            COUNTROWS ( WorkItems ),
            FILTER (
                ALL ( workitems ),
                OR (
                    ISBLANK ( WorkItems[ClosingIteration] ),
                    WorkItems[ClosingIteration] = _selectedIter
                )
                    && NOT ISBLANK ( WorkItems[TagNames] )
                        && AND (
                            NOT ISBLANK ( WorkItems[StartDate] ),
                            WorkItems[StartDateDay] <= _StartDate
                        )
                        && WorkItems[WorkItemType] = "Feature"
                        && WorkItems[State] <> "Removed"
            )
        )
    RETURN
        _checker

But I can't make it filter to filter out table. Please advise.

Helpful resources

Announcements
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!

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.