Qlik Community

QlikView Creating Analytics

Discussion Board for collaboration related to Creating Analytics for QlikView.

Announcements
Announcing the newest addition to the Qlik Community, Qlik Gallery! Learn More
Not applicable

Dates in a variables - how to set a date

I have a set analysis in a variable which restricts the X Axis from showing all the Week Endings

i.e. vWKENDMAX showing the last point on the x axis

=

date(max([Week Ending])-21) 

I now need the x axis to start at a specific point.  The activity in the graph start at specific point so for instance it would let me specify

vWKEND as

=01/01/2014 in the variable.

but because I have a rolling date range in my loading script I want the start point on the X axis to start either on this date or if the rolling range passes this point I want it to  read something like this:

=date(Min([Week Ending])+21) 

How would l write this please?

I tried an IF statement in my vWKEND but it didn't seem to work.

Please advise

Thank you


3 Replies
Highlighted

Re: Dates in a variables - how to set a date

Not sure what you are trying to accomplish. Would you be able to post some sample data with your expected output here?

Best,

S

Not applicable

Re: Dates in a variables - how to set a date

CaptureX axisStart point.JPG

I would like X axis to start from the approx 01/01/2014

Luminary
Luminary

Re: Dates in a variables - how to set a date

You would need to add set analysis into all of your expressions.

something like:

Sum( {<Date={">01/04/2015"}>}  Sales)

Once its working you can substitute the hardcoded date to a variable