Support Questions
Find answers, ask questions, and share your expertise
Announcements
Alert: Welcome to the Unified Cloudera Community. Former HCC members be sure to read and learn how to activate your account here.

Impala Kudu distribute by hash() not working

Solved Go to solution
Highlighted

Impala Kudu distribute by hash() not working

New Contributor

I have impala running on a Linux box (Version 2.7) and Kudu is  the storage manager. I am attempting to create a table via the docs in this fashion:

 

CREATE TABLE my_first_table ( id BIGINT, name STRING ) DISTRIBUTE BY HASH (id) INTO 16 BUCKETS TBLPROPERTIES( 'storage_handler' = 'com.cloudera.kudu.hive.KuduStorageHandler', 'kudu.table_name' = 'my_first_table', 'kudu.master_addresses' = 'kudu-master.example.com:7051', 'kudu.key_columns' = 'id' );

 

However, the "DISTRIBUTE BY HASH(id)" causes an invalid syntax near "DISTRIBUTE BY". This create table statement is coming directly from the docs (http://kudu.apache.org/docs/kudu_impala_integration.html#kudu_impala_insert_bulk). Any idea what I am doing wrong? I did notice that "partition by" works, but not the distribute clause.

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted

Re: Impala Kudu distribute by hash() not working

New Contributor

Thanks MJ, will definitely try that and let you know.

View solution in original post

5 REPLIES 5

Re: Impala Kudu distribute by hash() not working

Cloudera Employee

Hi, can you share the exact error you're receiving?

 

I assume your kudu master address is not kudu-master.example.com, have you tried setting that to the location of your server?

 

Thanks,

Matt

Highlighted

Re: Impala Kudu distribute by hash() not working

New Contributor

Yes, I did do that with the same error message.

Highlighted

Re: Impala Kudu distribute by hash() not working

New Contributor

Sorry didnt answer all your questions: The complete error is this:

 

AnalysisException: Syntax error in line 1: ... id BIGINT, name STRING ) DISTRIBUTE BY HASH (id) INTO... ^ Encountered: IDENTIFIER Expected: CACHED, COMMENT, LOCATION, PARTITIONED, PRODUCED, ROW, STORED, TBLPROPERTIES, UNCACHED, WITH CAUSED BY: Exception: Syntax error

Highlighted

Re: Impala Kudu distribute by hash() not working

Cloudera Employee

While Kudu is still in beta we have a sepecial version of Impala that we're calling 'Kudu_Impala'. If you're using the regular Impala 2.7 release you actually won't have the syntax for DISTRIBUTE BY. Can you try using the Impala version from these instructions: http://kudu.apache.org/docs/kudu_impala_integration.html

 

Thanks

Highlighted

Re: Impala Kudu distribute by hash() not working

New Contributor

Thanks MJ, will definitely try that and let you know.

View solution in original post

Don't have an account?
Coming from Hortonworks? Activate your account here