Don't miss your chance to take the Fabric Data Engineer (DP-700) exam on us!
Learn moreWe've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now
Hi guys
I am trying to calculate financial ratio’s Year of Year with a slicer.
In my database I have the financial data for the year 2020 + January 2021.
For example I calculated the ratio "solvability : equity / total liabilities".
Equity:
Eigen vermogen = -(CALCULATE('Measures JR'[SOM BS],Rubrieken[Rubriek]="Eigen vermogen")+[SOM PL])
Total liabilities:
Totaal vermogen = [Eigen vermogen]+[vreemd vermogen]
Loan capital: vreemd vermogen: = -(CALCULATE('Measures JR'[SOM BS],Rubrieken[Rubriek]="Vreemd vermogen KT") + CALCULATE('Measures JR'[SOM BS],Rubrieken[Rubriek]="Vreemd vermogen LT"))
Solvability:
Solvabiliteit = [Eigen vermogen]/[Totaal vermogen]
When I use my date filter ‘Year’ I receive for 2021 the mutations for that year and not the cumulated figure 2020 (openings balance) + 2021 as expected in a balance ratio.
I can select more cases in the filter but I was wondering If there is a formular to solve this problem?
ratio 2020
Kind regards,
Clélia
Solved! Go to Solution.
@CleliaComes , Formula which you need for last year is not clear , But you can Time intelligence with Date table to get measures for this year and last year example
YTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD('Date'[Date],"12/31"))
Last YTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD(dateadd('Date'[Date],-1,Year),"12/31"))
This year Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD(ENDOFYEAR('Date'[Date]),"12/31"))
Last year Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD(ENDOFYEAR(dateadd('Date'[Date],-1,Year)),"12/31"))
This can be done with separate year table with data at year level
This Year = CALCULATE(sum('order'[Qty]),filter(ALL('Date'),'Date'[Year]=max('Date'[Year])))
Last Year = CALCULATE(sum('order'[Qty]),filter(ALL('Date'),'Date'[Year]=max('Date'[Year])-1))
You can create measures for this year and last year and use those
Power BI — Year on Year with or Without Time Intelligence
https://medium.com/@amitchandak.1978/power-bi-ytd-questions-time-intelligence-1-5-e3174b39f38a
https://www.youtube.com/watch?v=km41KfM_0uA
To get the best of the time intelligence function. Make sure you have a date calendar and it has been marked as the date in model view. Also, join it with the date column of your fact/s. Refer :radacad sqlbi My Video Series Appreciate your Kudos.
Thanks a lot for your answer. With the integration of the time intelligence functions the problem was solved and I have nog the cumulated figure.
Kr
Clélia
@CleliaComes , Formula which you need for last year is not clear , But you can Time intelligence with Date table to get measures for this year and last year example
YTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD('Date'[Date],"12/31"))
Last YTD Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD(dateadd('Date'[Date],-1,Year),"12/31"))
This year Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD(ENDOFYEAR('Date'[Date]),"12/31"))
Last year Sales = CALCULATE(SUM(Sales[Sales Amount]),DATESYTD(ENDOFYEAR(dateadd('Date'[Date],-1,Year)),"12/31"))
This can be done with separate year table with data at year level
This Year = CALCULATE(sum('order'[Qty]),filter(ALL('Date'),'Date'[Year]=max('Date'[Year])))
Last Year = CALCULATE(sum('order'[Qty]),filter(ALL('Date'),'Date'[Year]=max('Date'[Year])-1))
You can create measures for this year and last year and use those
Power BI — Year on Year with or Without Time Intelligence
https://medium.com/@amitchandak.1978/power-bi-ytd-questions-time-intelligence-1-5-e3174b39f38a
https://www.youtube.com/watch?v=km41KfM_0uA
To get the best of the time intelligence function. Make sure you have a date calendar and it has been marked as the date in model view. Also, join it with the date column of your fact/s. Refer :radacad sqlbi My Video Series Appreciate your Kudos.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 53 | |
| 37 | |
| 35 | |
| 19 | |
| 17 |
| User | Count |
|---|---|
| 74 | |
| 69 | |
| 39 | |
| 35 | |
| 23 |