-
Notifications
You must be signed in to change notification settings - Fork 148
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
Unified OpenSearch PPL Data Type #3345
base: main
Are you sure you want to change the base?
Conversation
Signed-off-by: Peng Huo <[email protected]>
static { | ||
exprTypeToPPLType.put(ExprCoreType.BYTE, "tinyint"); | ||
exprTypeToPPLType.put(ExprCoreType.SHORT, "smallint"); | ||
exprTypeToPPLType.put(ExprCoreType.INTEGER, "int"); | ||
exprTypeToPPLType.put(ExprCoreType.LONG, "bigint"); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since this is a breaking change, why don't we directly change the old type to the new type, instead of introducing LangSpec
? Isn't this unnecessarily adding complexity?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree. The core type was not upgraded because I intended for the data type changes to affect only PPL and not SQL. This PR focuses on unifying PPL data types, while SQL data types can be addressed in a separate issue, as changes there would impact JDBC, ODBC, and CLI.
Ideally, the query engine should use well-defined data types, with LangSpec serving as the protocol for translating these engine types to language-specific types. Once the Calcite implementation is complete, CalciteDataType will translate to ExprDataType, and LangSpec will translate from ExprDataType to the PPL response data type.
Signed-off-by: Peng Huo <[email protected]>
Signed-off-by: Peng Huo <[email protected]>
Signed-off-by: Peng Huo <[email protected]>
Signed-off-by: Peng Huo <[email protected]>
Signed-off-by: Peng Huo <[email protected]>
Description
This PR introduces a language specification abstraction to support SQL and PPL query processing. The main changes include:
To Reviewer
Related Issues
#3339
Check List
--signoff
.By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.