[ 
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)

Reply via email to