Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SQL: Introduce proper SQL DATE type #37340

Closed
costin opened this issue Jan 11, 2019 · 2 comments
Closed

SQL: Introduce proper SQL DATE type #37340

costin opened this issue Jan 11, 2019 · 2 comments

Comments

@costin
Copy link
Member

costin commented Jan 11, 2019

In the spirit of #36440, ES SQL should be able to support a proper, date-only data type. As ANSI SQL already defines one through DATE once #36440 complete, ES SQL could have DataType.DATE added to describe a DATE only type.

Being a new date-time type, all date-related functionalities would need to take it into account:

a. grouping and histograms
The latter in particular should have the minimum interval of 1 day
b. date-time functions
As most work on the date component this is mainly a validation task
c. date-time math
Adding or extracting an interval. Worth looking into whether DATE-DATE makes sense or whether we should add a date function (e.g. DATE_DIFF).

@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-search

@matriv
Copy link
Contributor

matriv commented Jan 22, 2019

Created a new issue: #37692 to track the DATE - DATE functionality.

matriv added a commit to matriv/elasticsearch that referenced this issue Jan 22, 2019
Support ANSI SQL's DATE type by introducing a runtime-only
ES SQL date type.

Closes: elastic#37340
matriv added a commit that referenced this issue Jan 24, 2019
* SQL: Introduce SQL DATE data type

Support ANSI SQL's DATE type by introducing a runtime-only
ES SQL date type.

Closes: #37340
matriv added a commit that referenced this issue Jan 24, 2019
Support ANSI SQL's DATE type by introducing a runtime-only
ES SQL date type.

Closes: #37340
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants