Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Set analysis Last Year to date

I am running into some problems. I originally had  a set analysis that was showing last years invoice amount. It was just requested to show last year to date, so for example today, it would show invoice amounts from 01/01/2010 to 11/11/2010.

Original Expression:

Sum({1<[Year Applied]={$(=Year(Today())-1)}>} [Invoice Amount])

I can not figure out how to tell it to take only the dates of last year <=Today

I Tried this with no success: ([Date Applied M/D] is formatted to 'MM/DD' in the script)

Sum({1<[Year Applied]={$(=Year(Today())-1)},

[Date Applied M/D]={"<=$(=Date(Today(),'MM/DD'))"}

>} [Invoice Amount])

Help?

1 Solution

Accepted Solutions
Not applicable
Author

Can you try the below with date format as MM/DD/YYYY in script:

[Date Applied M/D]={"<=$(=Date(AddMonths(Today(),-12),'MM/DD/YYYY'))"}

Regards,

Kiran.

View solution in original post

3 Replies
Not applicable
Author

Can you try the below with date format as MM/DD/YYYY in script:

[Date Applied M/D]={"<=$(=Date(AddMonths(Today(),-12),'MM/DD/YYYY'))"}

Regards,

Kiran.

Not applicable
Author

That works perfectly, Thank you.

Not applicable
Author

Is there a sample QVW of this?