Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
alisonpwallis
Creator
Creator

Date Range Selection

Dear All

I have a chart where I want to show the expression only when the record is valid according to a user-selected date. For example, if the user wants to see what the position was up to yesterday, I want the totals shown to be those excluding today. I have several records for each ID and in addition to selecting only those that are valid up to and including the selected date I want to choose the maximum record that meets that criteria. The data comes from a table where status changes and their dates are recorded and I want to be able to recreate the position on a particular date. So if someone has 3 records dated 1/11/14 with status C/, 1/12/14 with status C/F and then 15/8/15 with status U/F I want to be able to access the record with the max date based on the user-selected date. So if the user selected 1/1/15 the record included in the expression calculation would be the one with C/F status. Then if I want to see what the position was for 1/9/15 I would get the record with the U/F status.

Something like: select max date where date <= today (if the user selected today).

I have tried already and can do it for 'today' but the users want to see the position in historic terms as well - for example last week, week before etc.

Here is an example of what I have done so far. I have a master calendar for the user to select from.

Any help would be really appreciated.

2 Replies
Not applicable

Hi,

use attached file.

if you want selection on Select Date then firstly link both table.

right now i prepared in [Date of Status Change].

Regards

Vimlesh

alisonpwallis
Creator
Creator
Author

Hi Vimlesh,

This is really useful thank you. I think it will help me a lot.

I wanted to check though, how do I select the max record when there are two for a particular ID that are within the selected date range?

Thanks

Alison