I am trying to create a calculation to show the variance between the select time period (based on the dashboard filter) and the previous year. It looks like I need to use the previous function - but I am receiving the below error. When I use this calculation the result is always zero
Select SalesCredit Business Line- SalesCredit Business Line where Year (Billingdatekey) = Previous
Best answer by Linda JView original
It looks like you are not adding the date attribute “Year” from the right-hand side menu.
Please see: https://help.gooddata.com/doc/enterprise/files/en/86795286/86795289/1/1554120241357/MAQL+syntax+2.png
You can find more information here: Get Started with Using MAQL to Write Metrics - Gooddata Free
And you can of course enroll to our University course for MAQL: Getting Started with MAQL (gooddata.com)
Let us know how it goes :)
Ok - when I select the Date Attribute. I am getting this result.
I made a change that got rid of the error - but see metric in action below. The results are clearly incorrect.
new - SalesCredit Business Line- SalesCredit Business Line for Previous(Year (Billingdatekey))without PF
I tried with and without the PF condition - with the same results.
New metric I am trying to create is SalesCreditBusinessLineLastYear
This topic can be closed as I have found I was selecting the wrong attribute in my calculation.