2
votes

I am encountering the same issue. After issuing the import command, i can locate it in the /user/hive/warehouse directory. But when in hive shell I issue the 'show tables' command, nothing is returned.

My import command looks like this:

./sqoop import --connect 'jdbc:sqlserver://192.168.1.1:1433;database=dbname;user=sa;password=password' -table customers --create-hive-table --hive-table mytable -target-dir /user/hive/warehouse/imports/ -as-textfile -split-by id -fields-terminated-by ',' -m 1 --hive-import

Any idea why that might be? Did i miss out any parameters?

Thank you

2

2 Answers

2
votes

Thank you for your resposne. Yes the file did appear in the hive directory.

I realised there was a missing property in my hive-site.xml.

<property>
    <name>javax.jdo.option.ConnectionURL</name>
    <value>jdbc:derby:;databaseName=metastore_db_directory;create=true</value>
</property>

Was able to run successfully after editing that

0
votes

Look ah hive directory. Is files where ? If yes try to create table and import files to that directory.