Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Create a table with filtered result from another table


Hello QV Community,

I'm trying to create a line chart with daily, weekly and monthly date points based on date range and do not know how to generate data points based on changing date range. My script generates daily, weekly and monthly points for all dates available and works fine as long as the range covers all availalbe dates, however when the range is changed, new data points need to be generated. Let's say my data includes 6/30 through 7/31 data, that accounts for 32 daily data points, 4 weekly (based on Fri) and 2 month end points used in drop down control. When a user specifies a custom range, he or she is presented with all available for this range daily/weekly or monthly points.

If the date range changes to 7/20 to 7/31, I need to regenerate all point to have 12 daily, 1 weekly and 1 monthly, with 7/20 daily point being 1, 7/25 weekly poing 1 and so on. I'm thinking of creating an internal table with filtered result set (but do not know how), however if there is another way to do it, I would appreciate any suggestion.

Below table depicts what i have after dashboard rebuild and what I need to have is date range changes:

On loadOn selection
Date PointDailyWeeky MonthlyDate PointDailyWeeky Monthly
6/30/20141 17/20/20141
7/1/20142 7/21/20142
7/2/20143 7/22/20143
7/3/20144 7/23/20144
7/4/201451 7/24/20145
7/5/20146 7/25/201461
7/6/20147 7/26/20147
7/7/20148 7/27/20148
7/8/20149 7/28/20149
7/9/201410 7/29/201410
7/10/201411 7/30/201411
7/11/2014122 7/31/201412 1
7/31/201432 2

Thank you in advance

Igor

5 Replies
Not applicable
Author

Hi there,

I believe the attached doc might help you. You can create a Variable event trigger to select the dates based on users From and To dates.

Hope this helps you

Thanks

AJ

Not applicable
Author

Hi Ajay,

Thanks for your response!

I have a working chart that is using variables defined by date range, however my challenge is to introduce data points that will get correctly recalculated based on selected range.

Thanks,

Igor

Not applicable
Author

Do you mind attaching your sample file. I think i might be missing something here.

Not applicable
Author

Ajay,

Please see below:

Besides allowing a user specify date range, we also need to provide ability to select data points. If you select 3 data points, the graph will only reflect 7/18, 7/21 and 7/23 dates, not 7/18 through 7/28 specified by range.

trend.PNG
trendfrequency.PNG

Not applicable
Author

If I understood correctly if user enters Date points as 5 then it will be 7/18,7/21,7/23,7/24,7/25.

If thats the case why dont you try Dimension Limits and display the lowest vValues where vValues is a variable that gets Date Points values from user.