Skip to main content
Announcements
Customer Spotlight: Discover what’s possible with embedded analytics Oct. 16 at 10:00 AM ET: REGISTER NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Set Analysis Where Date Is Greater Than

Trying to only calculate spend where a certain date field is greater than 12/01/2014. Current syntax I have is below but it is not working:

sum({<

Date = Date > {'12/01/2014'} }>}

Spend)

Any help is appreciated.

Thank you,

- dave

1 Solution

Accepted Solutions
b_garside
Partner - Specialist
Partner - Specialist

This will work. However you may not want a static/hard coded date search parameter.


Sum({$< [Data Type]={'A'} , Date={"> 12/01/2014"}>} Spend)

View solution in original post

8 Replies
swuehl
MVP
MVP

Try

sum(

{<Date = {">'12/01/2014'"} >}

Spend)

b_garside
Partner - Specialist
Partner - Specialist

This will work. However you may not want a static/hard coded date search parameter.


Sum({$< [Data Type]={'A'} , Date={"> 12/01/2014"}>} Spend)

Anonymous
Not applicable
Author

That did not seem to work. I have an additional statement in the set analysis ... Maybe this is why it does not work ...

sum({<

[Data Type]={'A'},

Date = {">'12/01/2014'"}>}

[Spend])

Anonymous
Not applicable
Author

Brian - Copied and pasted your solution verbatim but its not working for me. Perhaps I am doing something wrong ...

EDIT: I had an extra space between > and the date ... This now works. Thank you .

b_garside
Partner - Specialist
Partner - Specialist

Your welcome, Glad it worked.

Yeah Set Analysis is not to forgiving on syntax issues.

vanand3535
Creator III
Creator III

try this:-

Sum({$< [Data Type]={'A'} , Date={"> 12/01/2014"}>} Spend)

b_garside
Partner - Specialist
Partner - Specialist

Yeah the extra space was my bad. Glad you got it to work

publication1
Contributor III
Contributor III

Hi Brian, I have tried all these below and my value each time has been ZERO (0)

I have ran this in my database and answer should be 10

Do you see anything I am doing wrong (im thinking it can be a date format issue perhaps ?)

*** FAILED ATTEMPTS ***

COUNT({$<DELIVERY_DATE = {">04/12/2018"}>} ITEM_NAME)
COUNT({$<DELIVERY_DATE = {">04/12/2018"}>} ITEM_NAME)
COUNT({$<DELIVERY_DATE = {">'04/12/2018'"} >}ITEM_NAME)
COUNT({$<DELIVERY_DATE = {">'04/12/2018'"}>}[ITEM_NAME])
COUNT({$<DELIVERY_DATE = {">04/12/2018"}>}[ITEM_NAME])
COUNT({$<DELIVERY_DATE = {'>04/12/2018'}>}[ITEM_NAME])