Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I am trying to make a table with data for the past 5 days. This is the expression I am using:
Sum( {$< EventDate = {'$(vMaxDate)'},Account= -{'500','400'} >} Revenues).
What is the correct way to write this expression so that I have vMaxDate-1, vMaxDate-2......vMaxDate-5 in the set analysis? I have tried having the "-number" in different places in the equation but I keep on getting 0. Help appreciated.
Cheers.
Try:
Sum( {$< EventDate = {'$(=Date($(vMaxDate))-5)'},Account= {'*'}-{'500','400'} >} Revenues).
can you share the application?
this doesn't work
Hi Nag,
This returns the default value which I already have ie MaxDate. However, in the case of MaxDate-1,-2....-5, the value returned is 0.
Provide sample data...
Hi Jose,
This returns a zero value to my table.
Pradeep, unfortunately I don't know how I can share the application due to it's size, data model, sources and also without leaking sensitive info...
You can create some dummy data similar to your apps and share in excel file along with the output you required.
Based on the variable you shouldn't need that second dollar expand, I think the below should work
=SUM({<EventDate = {'>=$(=Date(vMaxDate-4))<=$(vMaxDate)'},Account= -{'500','400'}>}Revenues)
hope that helps
Joe
Hi Joe,
This expression gives me the sum of all revenues for 5 days. However I would like to have
Day 1: xxxx
Day 2: yyyy
Day 3: zzzz.
The formula as is does work though