You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@asterixdb.apache.org by "Ian Maxon (Jira)" <ji...@apache.org> on 2023/11/17 18:08:00 UTC
[jira] [Updated] (ASTERIXDB-3302) Compilation error when creating index with field type provided for field in closed type
[ https://issues.apache.org/jira/browse/ASTERIXDB-3302?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Ian Maxon updated ASTERIXDB-3302:
---------------------------------
Labels: triaged (was: )
> Compilation error when creating index with field type provided for field in closed type
> ----------------------------------------------------------------------------------------
>
> Key: ASTERIXDB-3302
> URL: https://issues.apache.org/jira/browse/ASTERIXDB-3302
> Project: Apache AsterixDB
> Issue Type: Bug
> Components: COMP - Compiler
> Reporter: Peeyush Gupta
> Priority: Major
> Labels: triaged
>
> The following index creation fails with error Compilation error: Typed index on 'name' field could be created only for open datatype
> {code:java}
> CREATE DATAVERSE test;
> USE test;
> CREATE TYPE t1 AS { id: int, name: string, phone:string };
> CREATE DATASET ds1(t1) primary key id;
> CREATE INDEX idx1 ON ds1(name: string); {code}
> Note that I have provided the same data type for name as in the type information. We should allow index creation on field type having a closed-type when there type is provided in the index creation statement as long as the type provided is same as their closed-type.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)