Learn how to configure Sqoop to enable users to specify custom Hive JDBC arguments
while importing data into Hive using Sqoop. This allows users to set Hive session variables,
Hive configuration values, and Hive user variables.
You can configure the required property either through Cloudera Manager or by using the --jdbc-arg argument
in your Sqoop import command. Use the hiveconf: prefix to specify Hive
configuration values and the hivevar: prefix to specify Hive user
variables.
Order of precedence
The configuration set through the Sqoop argument in the command line takes
precedence over the configuration specified through Cloudera Manager. If custom Hive JDBC arguments are
specified through both the command line and Cloudera Manager, the command line Sqoop argument does not entirely overwrite the Cloudera Manager configuration. Instead, the distinct
values are retained and the values with matching keys are replaced with
arguments specified through the command line Sqoop argument.
If you are specifying the custom Hive JDBC arguments through Cloudera Manager, perform the following steps:
In Cloudera Manager, click
Clusters and then select the
SQOOP_CLIENT-1 service.
From the Sqoop service, go to the Configuration
tab and search for sqoop.hive-jdbc-params.
Click and specify the custom Hive JDBC argument
and its value.
Click Save Changes.
If you are specifying the custom Hive JDBC arguments through the Sqoop
argument, specify the required key-value pair using the
--hive-jdbc-arg argument while constructing the Sqoop
import command.