Qlik Community

QlikView Layout & Visualizations

Discussion Board for collaboration on QlikView Layout & Visualizations.

Not applicable

set analysis with year

Hi,

wanted set analysis expression for July 17  2013 to 16 July 2014

6 Replies
Not applicable

Re: set analysis with year

Hi anil

Try this workaround! You will end up have the possibility to select a from and a to date....

http://community.qlik.com/message/397578#397578

Kind regards,

Anthony

Not applicable

Re: set analysis with year

Hi,

Suppose you have two date

let v_Start_date = 07/17/2013

let v_End_date = 07/16/2014

then write expression like this


Sum({<DateField = {">=$(=Date(v_Start_date)<=$(=Date(v_End_date)"} >} Value) 

Regards,

Vivek

satyadev_j
Valued Contributor

Re: set analysis with year

Hi,

Try below,

Sum({<DateField = {">=$(=Date(AddMonths(Today()+1,-12))<=$(=Date(Today()-1)"} >} Value)

Re: set analysis with year

Hi Anil,

Try the below expression which is dynamic and it works one day back every day and pick data from 12 months back to till date one day back as you give dates July 17  2013 to 16 July 2014.

=Sum({$<Date = {'>=$(=AddMonths(Date(Today()),-12)) <=$(=Date(Today()-1))'}>} Sales)

Re: set analysis with year

=SUM({<Date = {">=$(=Date(AddMonths(Today(),-12))<=$(=Date(Today()-1)))"}>}Sale)

Not applicable

Re: set analysis with year

first create two variable in Edit Script

Let vMinDate = 07/17/2013

Let vMaxDate = 07/16/2013

Then, in expression use this:

FUNCTION({<Date = {">$(vMinDate)<=$(vMaxDate)"}>} FIELD)

Hope this helps.

Community Browser