Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am creating a table with
FullDate Txnamount PrevDate MOM%
2024-04-01 $5000 2024-03-01 150
2024-03-01 $2000 2024-02-01 33
2024-02-01 $1500 2024-01-01 -
however when adding measure for MOM, it is not returning any value. Am new to set expressions
This was set expression I applied
(sum([txnamount])/ sum({FullDate.autoCalender.Date) = {“$(=Date(AddMonths(FullDate.autoCalendar.Date, -1))”}>} [atmtxnamt]) ) -1
If Your using months in Dimension, Try Below:
sum(aggr(
(sum({<Month>}Measure)-above(sum({<Month>}Measure)))
/
above(sum({<Month>}Measure))
,Month))
Else, pls share your sample data and output.
Hi Hirish thanks for your solution. However results are not returning correctly.
sample data
FullDate Month Year Txnamount
2024-04-01 Apr 2024 $2500
2024-04-01 Apr 2024 $1500
2024-04-01 Apr 2024 $1000
2024-03-01 Mar 2024 $1000
2024-03-01 Mar 2024 $1000
2024-02-01 Feb 2024 $500
2024-02-01 Feb 2024 $1000
Full date will always return first day of the month.
I have tried calling above(sum({<FullDate.autoCalendsr.Date>}[txnamount]))
but it’s returning blank
Hope you have created MonthName(FullDate) as MonthName in script, then use this as dimension.
This will be the expression:
Sum(Txnamount)/
above(sum(Txnamount))