Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi experts,
I used this function
Sum({1<[Month] ={"$(=Max([Month]))"}>} [turnover])
Sum({1<[Month ={"$(=Max([Month])-1)"}>} [turnover])
to calculate the turnover for the current month and the month before but in the result I still have 0. Can u help me please ??
thank u
Thank You.
Hi, can you confirm that it's turnover and not Turnover (with initial uppercase, it will be different fields)
If not maybe it's a format issued: one month is a number and the other is a string? anyway.. in script you can create a field with year and month as a number, it helps to compare january vs december:
Year(DateField)*12+Month(DateField) as YearMonthNum
Your expression should work with this field:
Sum({1<[YearMonthNum] ={"$(=Max([YearMonthNum]))"}>} [turnover])
Sum({1<[YearMonthNum] ={"$(=Max([YearMonthNum])-1)"}>} [turnover])
Hi, can you confirm that it's turnover and not Turnover (with initial uppercase, it will be different fields)
If not maybe it's a format issued: one month is a number and the other is a string? anyway.. in script you can create a field with year and month as a number, it helps to compare january vs december:
Year(DateField)*12+Month(DateField) as YearMonthNum
Your expression should work with this field:
Sum({1<[YearMonthNum] ={"$(=Max([YearMonthNum]))"}>} [turnover])
Sum({1<[YearMonthNum] ={"$(=Max([YearMonthNum])-1)"}>} [turnover])
Thank you so much