Forum Discussion

markmsc's avatar
markmsc
Resolver I
4 months ago
Solved

Filtering out zero/blank Matrix rows, part XXXVI

Hi all -- I have a variant of the old question "how do I filter out zero rows in a matrix visual" that I can't work out.  Surely it has been addressed in here somewhere, but I've not turned up the ri...
  • grazitti_sapna's avatar
    4 months ago

    Hi markmsc,

     

    You can try below measure and use it as a filter on table visual

     

    Inventory Row Filter =
    VAR NonZeroMonths =
    COUNTROWS(
    FILTER(
    ALLSELECTED('Date'[Month]), -- your column field (May, June, July)
    NOT ISBLANK(CALCULATE([Inventory])) &&
    CALCULATE([Inventory]) <> 0
    )
    )
    RETURN
    IF(NonZeroMonths > 0, 1, 0)

     

    ๐ŸŒŸ I hope this solution helps you unlock your Power BI potential! If you found it helpful, click 'Mark as Solution' to guide others toward the answers they need.
    ๐Ÿ’ก Love the effort? Drop the kudos! Your appreciation fuels community spirit and innovation.
    ๐ŸŽ– As a proud SuperUser and Microsoft Partner, weโ€™re here to empower your data journey and the Power BI Community at large.
    ๐Ÿ”— Curious to explore more? [Discover here].
    Letโ€™s keep building smarter solutions together!