Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

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

Set analysis Last Year to date

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.

3 Replies
Not applicable

Set analysis Last Year to date

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

Set analysis Last Year to date

That works perfectly, Thank you.

Not applicable

Set analysis Last Year to date

Is there a sample QVW of this?