Hi All,
I did created a database and table in hive, later i try to load the data using sqoop import to that table as shown below. But when i select that table i was getting a null values. Please advice.
hive> show databases;
OK
default
hadoopexam
hive> use hadoopexam;
OK
hive> show tables;
OK
departments
hive> desc departments;
OK
department_id int
department_name string
Time taken: 0.072 seconds, Fetched: 2 row(s)
hive> select * from departments;
OK
NULL NULL
NULL NULL
NULL NULL
NULL NULL
NULL NULL
NULL NULL
Time taken: 0.06 seconds, Fetched: 6 row(s)
Sqoop command which i am using as :-
sqoop import --connect jdbc:mysql://quickstart:3306/retail_db --username retail_dba --password cloudera --table departments --hive-home /user/hive/warehouse --hive-import --hive-overwrite --hive-table hadoopexam.departments;
Is anything missing ?