You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ignite.apache.org by "Konstantin Orlov (Jira)" <ji...@apache.org> on 2023/03/16 08:35:00 UTC
[jira] [Commented] (IGNITE-18798) Sql. Custom types. UUID literal.
[ https://issues.apache.org/jira/browse/IGNITE-18798?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17701040#comment-17701040 ]
Konstantin Orlov commented on IGNITE-18798:
-------------------------------------------
Currently it's impossible to create custom literal because of validation inside of SqlLiteral class (see {{org.apache.calcite.sql.SqlLiteral#valueMatchesType}}).
In Calcite 1.34 new type UNKNOWN has been added. We can try to use the new type to bypass this validation.
> Sql. Custom types. UUID literal.
> --------------------------------
>
> Key: IGNITE-18798
> URL: https://issues.apache.org/jira/browse/IGNITE-18798
> Project: Ignite
> Issue Type: Improvement
> Components: sql
> Affects Versions: 3.0.0-beta2
> Reporter: Maksim Zhuravkov
> Assignee: Konstantin Orlov
> Priority: Major
> Labels: calcite2-required, calcite3-required, ignite-3
>
> At the moment in order to specify a UUID user must use a cast operator (string -> uuid) or rely on implicit casts (which only work in some contexts). Implement UUID literal in parser to allow to define a UUID literal.
> {code:java}
> SELECT UUID 'fd10556e-fc27-4a99-b5e4-89b8344cb3ce';
> {code}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)