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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
atavo
Helper I
Helper I

Please Need DAX Help

ExampleExample

 

Hi trying to understand why my measure is not working the way it should. I have the following measures:

1. Amount: = SUM(Data[New Funds])

2. DecisionAmt: = CALCULATE([Amount],

                              USERELATIONSHIP (Calendar[Date],Data[Decision Date]))

3. DecisionAmt Declined: = CALCULATE([DecisionAmt],

                                             FILTER(

                                             VALUES(Data[Report Type]),

                                             Data[Report Type]="declined"

                                             ))

I have a table with Year-Month on the row with [DecisionAmt] and [DecisionAmt Declined] measures. Also, I have a slicer on Data[Report Type] column and I have sliced by "declined".

 

I had expected [DecisionAmt Declined] to show declined data for 2019-06 but it does not. Is this a bug or is my measure(i.e. [DecisionAmt Declined]) wrong.

 

Alfred

 

2 ACCEPTED SOLUTIONS

Very odd, somehow the FILTER in your measure was interacting with the context to exclude a row although I am not sure why.

This will return the correct amount for you:

DecisionAmt Declined = 
CALCULATE(
    [DecisionAmt],
    Data[Report Type]="declined"
)

View solution in original post

Thanks jdbuchanan

Would be interesting to know why DAX is behaving this way.

 

Alfred

View solution in original post

8 REPLIES 8
v-diye-msft
Community Support
Community Support

Hi ,

 

Actually I don't think it's needed to add the third measure if you just wanna the [DecisionAmt] changing by slicer, every time you click the slicer, the data will be filtered by specific type. 

But I believe the suggestion provided by @jdbuchanan71   does work. 

 

 

Community Support Team _ Dina Ye
If this post helps, then please consider Accept it as the solution to help the other members find it more
quickly.
jdbuchanan71
Super User
Super User

Hello @atavo 

That is odd, any chance you can share your .pbix file?

Hi jdbuchanan

Can do. Any chance I can get your email contact?

 

Not sure how to upload file on this site.

 

Alfred

Cmcmahan
Resident Rockstar
Resident Rockstar

I would be interested in seeing your .pbix too.  This is a super weird issue.  I'm curious what happens if you change the third measure to this: 

DecisionAmt Declined: = CALCULATE([DecisionAmt],
    FILTER(
        Data,
        Data[Report Type]="declined"
))

The best way to share .pbix files on this forum is to upload it to Google Drive, Dropbox, OneDrive, etc. and post the shareable link.  

Very odd, somehow the FILTER in your measure was interacting with the context to exclude a row although I am not sure why.

This will return the correct amount for you:

DecisionAmt Declined = 
CALCULATE(
    [DecisionAmt],
    Data[Report Type]="declined"
)

Thanks jdbuchanan

Would be interesting to know why DAX is behaving this way.

 

Alfred

Hi @atavo 

 

Could you tell me if your problem has been solved? If it is,kindly mark the helpful answer as a solution if you feel that makes sense. Welcome to share your own solution. others will benefit from here.

 

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

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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