Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi all,
I have a question referring a calculation. The table is bulid as follows:
Rows: "Counterparty"
Colums: "File Date" (hierachy from day to year)
Values: "Zinsberechnung"
I want to create a measure for the following calculation on a monthly base:
If "Sum of previous month" (how to define the variable for the previous month?) > 0, then 0,
If "Value on the first day from the following month" is not 0, than 0, else show the cumulative amount of all values until this day.
Thank you very much for your help!
BR
Solved! Go to Solution.
Hi, @Anonymous
I'm trying to simulate your data, not sure if it's accurate.
Trying to calculate "sum of previous month" with measure is not very comparative. I tried to do some operations with the calculation column to see if it is helpful to you.
month = MONTH('Table'[File Date])
previous month = [month]-1
Sum of previous month =
CALCULATE (
SUM ( 'Table'[Zinsberechnung] ),
FILTER (
ALL ( 'Table' ),
[Counterparty] = EARLIER ( 'Table'[Counterparty] )
&& [month] = EARLIER ( 'Table'[previous month] )
)
)
IF = IF([Sum of previous month]>0,"0",BLANK())
If the method I provided above can't solve your problem, what's your expected result? Could you please provide more details for it?
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi, @Anonymous
I'm trying to simulate your data, not sure if it's accurate.
Trying to calculate "sum of previous month" with measure is not very comparative. I tried to do some operations with the calculation column to see if it is helpful to you.
month = MONTH('Table'[File Date])
previous month = [month]-1
Sum of previous month =
CALCULATE (
SUM ( 'Table'[Zinsberechnung] ),
FILTER (
ALL ( 'Table' ),
[Counterparty] = EARLIER ( 'Table'[Counterparty] )
&& [month] = EARLIER ( 'Table'[previous month] )
)
)
IF = IF([Sum of previous month]>0,"0",BLANK())
If the method I provided above can't solve your problem, what's your expected result? Could you please provide more details for it?
Best Regards,
Community Support Team _Charlotte
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Please provide sanitized sample data that fully covers your issue. Paste the data into a table in your post or use one of the file services. Please show the expected outcome.
Vielen Dank im Voraus.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
112 | |
100 | |
80 | |
64 | |
57 |
User | Count |
---|---|
146 | |
110 | |
93 | |
84 | |
67 |