Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
sum({<feeddate={$(=addmonths(feeddate,-1))}>} total <[CSS Dimension]>TurnoverPopulationFlag)
I can't get the above expression to work. If I hardcode feeddate={'5/1/2011'}, it works. I've also tried using double quotes after looking at examples.
sum({<feeddate={"$(=addmonths(feeddate,-1))"}>} total <[CSS Dimension]>TurnoverPopulationFlag)
Can someone tell me what I'm doing wrong? Thanks!
try with single quotes
sum({<feeddate={'$(=addmonths(feeddate,-1))'}>} total <[CSS Dimension]>TurnoverPopulationFlag)
Do you have a single possible value for feeddate?
Thanks. I tried with single quotes and that also gives me zeros. There are definitely values for feeddate. When I use this expression, addmonths(feeddate,-1) I get the previous month's feeddate for each month selected. Any other ideas?
try this, add a text object to the sheet and have this as the formula
=
'$(=addmonths(feeddate,-1))'
OK...I'm not really sure what I'm supposed to do. Which tab in Text Object Properties is the formula supposed to go? Also, what will adding a text object accomplish?
Yes, text object formula.
It will show you what the expression '$(=addmonths(feeddate,-1))' is resolving to.
You could also try posting a sample app, that will be easier than going back and forth with messages.
the text object remains blank. I tried diplaying fields and those don't appear either - =feeddate, =Range
the text object remains blank. I tried diplaying fields and those don't appear either - =feeddate, =Range
You will only get a value when there is just one possible option, just like with the expression you're trying to include in your set analysis.
Going back to the basics, what exactly are you trying to achieve in the graph/table?
for any selected date range (Apr 2011, May 2011, Jun 2011, etc), I'm trying to get the average headcount which is defined as current headcount plus prior headcount divided by 2.
((sum(TurnoverPopulationFlag) + sum({<feeddate={$(=addmonths(feeddate,-1))}>} total <[CSS Dimension]>TurnoverPopulationFlag))/2)
I need to look back at the previous month somehow. I'm confused at to why =addmonths(feeddate,-1) will display results when used alone, but doesn't work when used within the Sum.
addmonths(feeddate,-1) addmonths(feeddate,-1) addmonths(feeddate,-1) sum({<feeddate={''}>} total <[CSS Dimension]>TurnoverPopulationFlag)
//sum({<feeddate={'$(=AddMonths(feeddate,1))'}>} total <[CSS Dimension]>TurnoverPopulationFlag)sum({<feeddate={''}>} total <[CSS Dimension]>TurnoverPopulationFlag)
//sum({<feeddate={'$(=AddMonths(feeddate,1))'}>} total <[CSS Dimension]>TurnoverPopulationFlag)sum({<feeddate={''}>} total <[CSS Dimension]>TurnoverPopulationFlag)
//sum({<feeddate={'$(=AddMonths(feeddate,1))'}>} total <[CSS Dimension]>TurnoverPopulationFlag)Jun 2011 May 2011 Apr 2011 Jun 2011 May 2011 Apr 2011 5/1/2011 4/1/2011 3/1/2011 0 0 0 5/1/2011 4/1/2011 3/1/2011 0 0 0 5/1/2011 4/1/2011 3/1/2011 0 0 0 5/1/2011 4/1/2011 3/1/2011 0 0 0 5/1/2011 4/1/2011 3/1/2011 0 0 0 5/1/2011 4/1/2011 3/1/2011 0 0 0 5/1/2011 4/1/2011 3/1/2011 0 0 0 5/1/2011 4/1/2011 3/1/2011 0 0 0 5/1/2011 4/1/2011 3/1/2011 0 0 0 5/1/2011 4/1/2011 3/1/2011 0 0 0