Qlik Community

QlikView Layout & Visualizations

Discussion Board for collaboration on QlikView Layout & Visualizations.

Highlighted
christiana
New Contributor III

Variable date range calculation in Set Analysis

Dear all,

I'm trying to set up a layout with date calculations within the Set Analysis.

Background: user should be able to choose a key date and the AR overdue date ranges he wants to look at.

Example: Key date is 31.05.2019, the AR overdue ranges are 30, 60 and 90.

My formula looks currently like this:

sum({<DueDate={">=($(vKeyDate)-$(vCateg2)) <=$(vKeyDate)-$(vCateg1) "}>} Amount)

in Words: the sum of the field amount should be calculated when the duedate is greater than 01.04.2019 and less than 01.05.2019.

What am I doing wrong?

Many thanks for your help!

1 Solution

Accepted Solutions
Highlighted

Re: Variable date range calculation in Set Analysis

Look at the attached

image.png

View solution in original post

4 Replies
Highlighted
Partner
Partner

Re: Variable date range calculation in Set Analysis

Move the calculation to a single variable

e.g. $(vKeyDate)-$(vCateg2) to vKeyDateLow

and change expression to

Sum({<DueDate={">=$(=vKeyDateLow) <=$(=vKeyDateMax)"}>} Amount)

Highlighted
christiana
New Contributor III

Re: Variable date range calculation in Set Analysis

Unfortunately I'm not able to make it work.

I have attached a sample qvw file.

Any idea what is going wrong?

Highlighted

Re: Variable date range calculation in Set Analysis

Look at the attached

image.png

View solution in original post

Highlighted
christiana
New Contributor III

Re: Variable date range calculation in Set Analysis

Many many thanks to you!

I transfered it to my Qlikview application and it is working!

Thanks a lot for your quick support and help!