You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "Shuyi Chen (JIRA)" <ji...@apache.org> on 2018/02/08 03:16:00 UTC
[jira] [Comment Edited] (CALCITE-2045) Support "CREATE TYPE" DDL
[ https://issues.apache.org/jira/browse/CALCITE-2045?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16356429#comment-16356429 ]
Shuyi Chen edited comment on CALCITE-2045 at 2/8/18 3:15 AM:
-------------------------------------------------------------
Hi [~julianhyde], I think I'll need to extend SqlDataTypeSpec to pass the schema (or something equivalence to provide access to the registered UDT) for SqlDataTypeSpec.deriveType(). Otherwise, after I create a type using "_CREATE TYPE mytype1 as int_", when I use the type to, say, _create table t (c mytype1),_ it will fail. Because the type info is only registered in the schema, and SqlDataTypeSpec has to access the created user-defined type through schema. However, this might be difficult because not all call sites of SqlDataTypeSpec.deriveType can provide access to the schema. If this is the right option, I can try to modify all call sites to provide access to the schema directly or indirectly. Do you have any suggestions?
was (Author: suez1224):
Hi [~julianhyde], I think I'll need to extend SqlDataTypeSpec to pass the schema (or something equivalence to provide access to the registered UDT) during SqlDataTypeSpec.deriveType call. Otherwise, after I create a type using "_CREATE TYPE mytype1 as int_", when I use the type to, say, _create table t (c mytype1),_ it will fail. Because the type info is only registered in the schema, and SqlDataTypeSpec has to access the created user-defined type through schema. However, this might be difficult because not all call sites of SqlDataTypeSpec.deriveType can provide access to the schema. If this is the right option, I can try to modify all call sites to provide access to the schema directly or indirectly. Do you have any suggestions?
> Support "CREATE TYPE" DDL
> -------------------------
>
> Key: CALCITE-2045
> URL: https://issues.apache.org/jira/browse/CALCITE-2045
> Project: Calcite
> Issue Type: New Feature
> Components: core
> Reporter: Shuyi Chen
> Assignee: Shuyi Chen
> Priority: Major
>
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)