GitHub user dosubot[bot] added a comment to the discussion: Date Filter

<!-- Answer -->
Superset's date filter is designed to be inclusive for the start date and 
exclusive for the end date—this is reflected both in the SQL expression it 
generates (`date_column >= 'start_date' AND date_column < 'end_date'`) and in 
the UI labels and tooltips ["Start (inclusive)", "End 
(exclusive)"](https://github.com/apache/superset/blob/master/superset-frontend/src/explore/components/controls/DateFilterControl/components/AdvancedFrame.tsx).
 There isn't a configuration option to make both endpoints inclusive; the logic 
is hardcoded this way and confirmed in the 
[changelog](https://github.com/apache/superset/blob/master/superset-frontend/CHANGELOG.md).

If you need both endpoints to be inclusive, you can manually adjust the end 
date (for example, set it to the next day) or customize your SQL expression in 
an ad hoc query or dataset.


<!-- Dosu Comment Footer -->
*To reply, just mention [@dosu](https://go.dosu.dev/dosubot).*

---
<sup>How did I do? 
[Good](https://app.dosu.dev/response-feedback/1d18dab6-ae23-4bac-862c-0e1167763c72?feedback_type=great_response)
 | 
[Irrelevant](https://app.dosu.dev/response-feedback/1d18dab6-ae23-4bac-862c-0e1167763c72?feedback_type=irrelevant_answer)
 | 
[Incorrect](https://app.dosu.dev/response-feedback/1d18dab6-ae23-4bac-862c-0e1167763c72?feedback_type=incorrect_sources)
 | 
[Verbose](https://app.dosu.dev/response-feedback/1d18dab6-ae23-4bac-862c-0e1167763c72?feedback_type=too_verbose)
 | 
[Hallucination](https://app.dosu.dev/response-feedback/1d18dab6-ae23-4bac-862c-0e1167763c72?feedback_type=hallucination)
 | [Report 
🐛](https://app.dosu.dev/response-feedback/1d18dab6-ae23-4bac-862c-0e1167763c72?feedback_type=bug_report)
 | 
[Other](https://app.dosu.dev/response-feedback/1d18dab6-ae23-4bac-862c-0e1167763c72?feedback_type=other)</sup>

[![Chat with 
Dosu](https://dosu.dev/dosu-chat-badge.svg)](https://app.dosu.dev/a28d3c7e-a9d3-459e-9fb6-3a6f9ff4f357/ask?utm_source=github)&nbsp;[![Open
 in 
Cursor](https://dosu.dev/dosu-in-cursor.svg)](https://cursor.com/link/prompt?text=Superset%27s%20date%20filter%20is%20designed%20to%20be%20inclusive%20for%20the%20start%20date%20and%20exclusive%20for%20the%20end%20date%E2%80%94this%20is%20reflected%20both%20in%20the%20SQL%20expression%20it%20generates%20%28%60date_column%20%3E%3D%20%27start_date%27%20AND%20date_column%20%3C%20%27end_date%27%60%29%20and%20in%20the%20UI%20labels%20and%20tooltips%20%5B%22Start%20%28inclusive%29%22%2C%20%22End%20%28exclusive%29%22%5D%28https%3A//github.com/apache/superset/blob/master/superset-frontend/src/explore/components/controls/DateFilterControl/components/AdvancedFrame.tsx%29.%20There%20isn%27t%20a%20configuration%20option%20to%20make%20both%20endpoints%20inclusive%3B%20the%20logic%20is%20hardcoded%20this%20way%20and%20confirmed%20in%20the%20%5Bc
 
hangelog%5D%28https%3A//github.com/apache/superset/blob/master/superset-frontend/CHANGELOG.md%29.%0A%0AIf%20you%20need%20both%20endpoints%20to%20be%20inclusive%2C%20you%20can%20manually%20adjust%20the%20end%20date%20%28for%20example%2C%20set%20it%20to%20the%20next%20day%29%20or%20customize%20your%20SQL%20expression%20in%20an%20ad%20hoc%20query%20or%20dataset.)&nbsp;[![Join
 
Discord](https://img.shields.io/badge/join-5865F2?logo=discord&logoColor=white&label=)](https://go.dosu.dev/discord-bot)&nbsp;[![Share
 on 
X](https://img.shields.io/badge/X-share-black)](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/apache/superset/discussions/37192)

GitHub link: 
https://github.com/apache/superset/discussions/37192#discussioncomment-15514145

----
This is an automatically sent email for [email protected].
To unsubscribe, please send an email to: 
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to