You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
MySQL has no such type, at least visible to user, but having a such type we can simplify processing few datetime functions.
... number in YYMMDD, YYMMDDhhmmss, YYYYMMDD, or YYYYMMDDhhmmss format. If the argument includes a time part, it may optionally include a fractional seconds part.
See PERIOD_ADD/PERIOD_DIFF functions in MySQL docs for reference.
The proposed solution would help fixing NOW() + 0 issue, see discussion in #754 and Bit-Quill#92.
What solution would you like?
A new data type PERIOD
Responsible for parsing and formatting
Couldn't be casted to numeric types
Expose a numeric type for user
Has operators + and - overloaded with integers.
This will also simplify UNIX_TIMESTAMP implementation (#835)
Is your feature request related to a problem?
MySQL has no such type, at least visible to user, but having a such type we can simplify processing few datetime functions.
See
PERIOD_ADD
/PERIOD_DIFF
functions in MySQL docs for reference.The proposed solution would help fixing
NOW() + 0
issue, see discussion in #754 and Bit-Quill#92.What solution would you like?
A new data type
PERIOD
+
and-
overloaded with integers.This will also simplify
UNIX_TIMESTAMP
implementation (#835)sql/core/src/main/java/org/opensearch/sql/expression/datetime/DateTimeFunction.java
Lines 915 to 938 in e04d6f8
Other functions affected: all listed in #754,
EXTRACT
,UTC_DATE
,UTC_TIME
andUTC_TIMESTAMP
(link).What alternatives have you considered?
Keep using numeric type.
Do you have any additional context?
#855
#722
#835
The text was updated successfully, but these errors were encountered: