You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues-all@impala.apache.org by "ASF subversion and git services (Jira)" <ji...@apache.org> on 2023/05/02 16:12:00 UTC
[jira] [Commented] (IMPALA-11809) Support non unique primary key for Kudu
[ https://issues.apache.org/jira/browse/IMPALA-11809?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17718634#comment-17718634 ]
ASF subversion and git services commented on IMPALA-11809:
----------------------------------------------------------
Commit 296224a6fb5c461a22920eac4f06815b8dd26068 in impala's branch refs/heads/master from wzhou-code
[ https://gitbox.apache.org/repos/asf?p=impala.git;h=296224a6f ]
IMPALA-12110: Create Kudu table in CTAS without specifying primary key
IMPALA-11809 adds support non unique primary key for Kudu table.
It allows to create Kudu table without specifying primary key since
partition columns could be promoted as non unique primary key. But
when creating Kudu table in CTAS without specifying primary key,
Impala returns parsing error.
This patch fixed the parsing issue for creating Kudu table in CTAS
without specifying primary key.
Testing:
- Added new test cases in parsing unit-test and end-to-end unit-test.
- Passed core tests.
Change-Id: Ia7bb0cf1954e0a4c3d864a800e929a88de272dd5
Reviewed-on: http://gerrit.cloudera.org:8080/19825
Reviewed-by: Abhishek Chennaka <ac...@cloudera.com>
Reviewed-by: Riza Suminto <ri...@cloudera.com>
Tested-by: Impala Public Jenkins <im...@cloudera.com>
> Support non unique primary key for Kudu
> ---------------------------------------
>
> Key: IMPALA-11809
> URL: https://issues.apache.org/jira/browse/IMPALA-11809
> Project: IMPALA
> Issue Type: New Feature
> Components: Backend, Catalog, Frontend
> Affects Versions: Impala 4.3.0
> Reporter: Wenzhe Zhou
> Assignee: Wenzhe Zhou
> Priority: Major
> Fix For: Impala 4.3.0
>
>
> Kudu engine adds support for non unique primary key. It adds a column 'auto_increment_id' automatically in a table which has non unique primary key. The non unique primary key and 'auto_increment_id' form unique composite primary key for the table.
> Impala need to add syntactic support for creating Kudu table with non unique primary key like:
> CREATE TABLE tbl (i INT NON UNIQUE PRIMARY KEY, s STRING)
> PARTITION BY HASH (i) partitions 3
> STORED as KUDU;
>
> CREATE TABLE tbl (i INT, s STRING, NON UNIQUE PRIMARY KEY(i))
> PARTITION BY HASH (i) partitions 3
> STORED as KUDU;
>
> CREATE TABLE tbl NON UNIQUE PRIMARY KEY(id)
> PARTITION BY HASH (id) partitions 3
> STORED as KUDU
> AS SELECT id, string_col FROM functional.alltypes WHERE id = 10;
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-all-unsubscribe@impala.apache.org
For additional commands, e-mail: issues-all-help@impala.apache.org