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

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes! Register now.

Reply
Anonymous
Not applicable

Need help with power bi

 

# of Projects in Progress =
CALCULATE (
    COUNTROWS ( DataDump1 ),
    FILTER ( DataDump1, DataDump1[Vendor] = EARLIER ( DataDump1[Vendor] ) ),
    FILTER (
        DataDump1,
        DataDump1[Subject Matter] = EARLIER ( DataDump1[Subject Matter] )
    ),
    AND (
        FILTER ( DataDump1, DataDump1[Sent To Accounting Date].[Date] = BLANK () ),
        FILTER ( DataDump1, DataDump1[POWord Count] > 0 )
    )
)

 

Here is my Dax syntax. When I use this syntax it will filter and count the rows I am looking for, however, it leaves off the last filter FILTER(DataDump1,DataDump1[POWord Count] > 0)

 

Can someone please help me correct this so my syntax will filter the columns and filter if the date field is empty and word count is greater than 0? Thank you!

1 ACCEPTED SOLUTION
v-cherch-msft
Microsoft Employee
Microsoft Employee

Hi @Anonymous

 

You may try below DAX:

Column  =
IF (
    DataDump1[POWord Count] > 0
        && DataDump1[Sent To Accounting Date].[Date] <> BLANK (),
    COUNTROWS (
        FILTER (
            DataDump1,
            DataDump1[Vendor] = EARLIER ( DataDump1[Vendor] )
                && DataDump1[Subject Matter] = EARLIER ( DataDump1[Subject Matter] )
        )
    )
)

Regards,

Cherie

Community Support Team _ Cherie Chen
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-cherch-msft
Microsoft Employee
Microsoft Employee

Hi @Anonymous

 

You may try below DAX:

Column  =
IF (
    DataDump1[POWord Count] > 0
        && DataDump1[Sent To Accounting Date].[Date] <> BLANK (),
    COUNTROWS (
        FILTER (
            DataDump1,
            DataDump1[Vendor] = EARLIER ( DataDump1[Vendor] )
                && DataDump1[Subject Matter] = EARLIER ( DataDump1[Subject Matter] )
        )
    )
)

Regards,

Cherie

Community Support Team _ Cherie Chen
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
ChrisMendoza
Resident Rockstar
Resident Rockstar

@Anonymous,

 

Not an answer for your issue but, rather a suggestion to help get your solution answered sooner rather than later:

 

Use the Insert Code feature for your post and format your code block so it can be more easily read like:

 

# of Projects in Progress =
CALCULATE (
    COUNTROWS ( DataDump1 ),
    FILTER ( DataDump1, DataDump1[Vendor] = EARLIER ( DataDump1[Vendor] ) ),
    FILTER (
        DataDump1,
        DataDump1[Subject Matter] = EARLIER ( DataDump1[Subject Matter] )
    ),
    AND (
        FILTER ( DataDump1, DataDump1[Sent To Accounting Date].[Date] = BLANK () ),
        FILTER ( DataDump1, DataDump1[POWord Count] > 0 )
    )
)

I use http://www.daxformatter.com/ for formatting.






Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

Proud to be a Super User!



Anonymous
Not applicable

Thank you for the advice! @ChrisMendoza

Helpful resources

Announcements
September Power BI Update Carousel

Power BI Monthly Update - September 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors