Reply
Highlighted
Explorer
Posts: 7
Registered: ‎07-31-2017

Passing server side query options to Impala using Hive-JDBC driver

I use mt_dop=n parameter extensively and want to pass it from connection string.

While using Cloudera Impala driver, the below query string works:

jdbc:impala://192.168.123.123:21050/;mt_dop=8

 

However when we use Hive JDBC driver, the below query string doesnt work:

jdbc:hive2://192.168.174.72:21050/;auth=noSasl;mt_dop=8

 

I have tried lots of alternatives for Hive connection string like 

jdbc:hive2://192.168.174.72:21050/;auth=noSasl?mt_dop=8

jdbc:hive2://192.168.174.72:21050/;auth=noSasl#mt_dop=8

 

but none of them work.

 

Can anyone give me a way out to pass this query option using Hive JDBC driver ?

Cloudera Employee
Posts: 257
Registered: ‎07-29-2015

Re: Passing server side query options to Impala using Hive-JDBC driver

Hi Sanjay,

  Cloudera doesn't support using the Hive JDBC driver so it may not work in all cases - I think it is something that's provided by the Apache Hive project.

Explorer
Posts: 7
Registered: ‎07-31-2017

Re: Passing server side query options to Impala using Hive-JDBC driver

As per 

https://www.cloudera.com/documentation/enterprise/5-9-x/topics/impala_jdbc.html#jdbc_driver_choice 

In Impala 2.0 and later, you have the choice between the Cloudera JDBC Connector and the Hive 0.13 JDBC driver. Cloudera recommends using the Cloudera JDBC Connector where practical.

 

I take this to mean that Impala should support both drivers.

Announcements