By default, when you create Date & time range filter, “Include end date” is disabled.
QuickSight does not allow it to be enabled without setting some default start and end dates. If you try to apply without setting some start and end date, you will get an error “Select a start date” and “Select an end date”.
welcome to the QuickSight Community!
Under Condition you can choose if you want to use a before or after date for your date filter.
So you can filter for just a start or an end date depending on you wishes:
“Before” or “After” condition is a different filter, where user does not define a range but instead sets start date, or end date for filtering data.
However, I would like user to be able to select a date range (start and end date), for which the data is filtered. The default “Between” condition is exactly what I want, with the exception that I would like to include the end date (which is excluded by default).
For example, if user selects dates from 1st of June until 31st of July, I want data from 31st of July to be included. By default the last day is excluded and most users would expect it to be included.
Problem is, the user interface does not allow me to apply any changes to the filter without typing in some date into the date field. I can’t even change th condition to “Before” if I would want to, since clicking “Apply” gives me error that I have not selected start date or end date.
Hi @Oke,
I would say this is more of a limitation than a bug. By default, with date filters, it’s always going to require a start and end date since you’re trying to recognize information between two set dates.
I will mark this as a feature request as it’s a bit interesting that you’re able to show a blank value by default for other filter types but not for a date.
Thanks for your reply! I don’t understand the requirement to define a default value for filters. In most use cases, the filters are there for the user to be able to filter data through controls when needed. The user should be able to choose which date ranges to filter instead of the developer of the app to forcing a specific data to be filtered by default.
In my case, there is no need for any dates to be filtered by default and in fact it would ruin the app, because some data has null values for the dates and those would be excluded, which is not desirable. If I would select “Include nulls” from Null options, it will cause the nulls to be included even when user selects some date range, which is not desirable either.
In fact, the default behavior of the filter (when date range filter is created and no default dates are given) works exactly in a desirable way, e.g. if user has not selected any data range from the control, nothing is filtered and all data is displayed. If user selects some data range from control, it includes only the data rows which have the date in the selected range.
Only problem is that the last date of the selected date range is not included by default. This is counter-intuitive. Most users will expect the selected end date to be included. Let’s say I want to select date range from beginning of June until end of July. I would select the date range from 2024-06-01 to 2024-07-31. However, by default, the date range filter would exclude any data from the date 2024-07-31 and actual data will be displayed only until 2024-07-30. This is because “Include end date” checkbox is disabled by default and there is no way to enable this without defining default start and end dates, which makes the filter stop working in desirable way.
Not sure if this is of any help, but on the occasions I have found it to not include the end date even though the date is selected, I have had to add the time in as well as the date as it was defaulting to 2024-07-31 00:00:00, updating the time part to 23:59 has then included the data for the whole period.
Hello @Oke, why don’t you set the end date to a rolling end date of today? Something that would ensure it is always somewhat relevant. Then the user can update it if they would want, but it would also allow you to set the include end date check mark.
In order for it to reference a value as an end date, something must be populated. Using today would likely be the easiest way to manage this issue.
I can also tag this topic as a feature request for the include end date check box to be the default functionality. Thank you for your feedback!
Thanks for your reply and thank you for tagging it as a feature request.
The reason I don’t want to set any default values for the date range is that I have rows in my data where the date field is null. I want these rows to be shown in the data by default. Someone may ask, why don’t I enable the “Include nulls” from the filter’s Null options. The reason is that when user has selected a specific date range, he should only see the rows where date is within the selected range and not those rows where date is null. “Include nulls” will include the null rows always which is not good.
Every other filter in QuickSight, and in any BI tool in general, works in following way:
If user has not selected anything from filter, show all data
If user selects something from filter, show data that user selected
This is the logical way that filters should work, and this is also the way QuickSight’s date range filter works by default it you don’t touch the properties. Once you try to modify any properties of the filter, the date range filter suddenly forces the developer to pre-define a specific range to be filtered which is strange.
If the “include end date” is checked by default, it will fix this particular problem but most logical fix would be to remove the requirement for developer to pre-define a specific date range when editing properties of the filter.
Hello @Oke, I completely understand your frustrations and I also appreciate all of the detailed feedback. I will archive this topic for our support team. Thank you!