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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Dax Calculation Help

Dear All,

 

 

I am making a property management report, where I am calculating what is *Revenue Recognition* to calculate that I have two date fields one *[Revenue Start Date]* & *[Revenue End Date]* now, i made date calender using min date and max date of start and end fields 

i have give two inActive relation now, how would i calculate the amount ???

Revnue Recognition Amt = calculate(sum(table[Amt]),userrelationship(table[Revenue Start Date], Dates[date])
OR

Revnue Recognition Amt = calculate(sum(table[Amt]),userrelationship(table[Revenue End Date], Dates[date])

 

which one is correct, how would i calculate the exact amount

 

I want to put this into a tabular form where property name and month name with exact amount

 

 

please help

1 ACCEPTED SOLUTION
Greg_Deckler
Community Champion
Community Champion

@Anonymous Both are incorrect in that the function is USERELATIONSHIP, not USERRELATIONSHIP. If you fix that then the correct one is dpendent on what you are trying to achieve. What you might want is something like:


Take a look at these two Quick Measures as I think you want something like them.

https://community.powerbi.com/t5/Quick-Measures-Gallery/Open-Tickets/m-p/409364
https://community.powerbi.com/t5/Quick-Measures-Gallery/Periodic-Billing/m-p/409365



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

2 REPLIES 2
v-jingzhang
Community Support
Community Support

Hi @Anonymous 

 

It depends on which dates you want to filter by when calculating the Sum. If you want to filter the table by Start Date, you can use the former one. If you want to filter the table by End Date, you can use the latter one. Here is a blog that may be helpful: How To Work With Multiple Dates In Power BI | Enterprise DNA

 

Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.

Greg_Deckler
Community Champion
Community Champion

@Anonymous Both are incorrect in that the function is USERELATIONSHIP, not USERRELATIONSHIP. If you fix that then the correct one is dpendent on what you are trying to achieve. What you might want is something like:


Take a look at these two Quick Measures as I think you want something like them.

https://community.powerbi.com/t5/Quick-Measures-Gallery/Open-Tickets/m-p/409364
https://community.powerbi.com/t5/Quick-Measures-Gallery/Periodic-Billing/m-p/409365



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.