Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Plain View
Sqoop >> mail # user >> import from Oracle to Hive : 2 errors


+
Jérôme Verdier 2013-06-17, 13:46
+
Jarek Jarcec Cecho 2013-06-17, 14:58
+
Jérôme Verdier 2013-06-17, 15:31
Copy link to this message
-
Re: import from Oracle to Hive : 2 errors
Hi Jerome,
I've noticed that you've already overcome this issue, however let me explain what has happened for purpose of future readers.

Oracle connector is overloading parameter --table for specifying both table name and owner name. However as this is specific only to the Oracle connector, other Sqoop parts are still expecting only a table name inside the --table parameter. For example the Hive import part of Sqoop will interpret the parameter value in form OWNER.TABLE as DATABASE.TABLE for Hive and in case that the DATABASE do not exists, it will fail. The workaround is to specify the --hive-table parameter to set correct table name without the owner part.

Jarcec

P.S. - This and many others Sqoop use cases are very deeply described in upcoming Sqoop Cookbook:

http://shop.oreilly.com/product/0636920029519.do

On Mon, Jun 17, 2013 at 05:31:52PM +0200, Jérôme Verdier wrote:
> Hi Jarcec,
>
> Thanks for your answer, you're always very helpful =)
>
> i think that my Hive installation is OK, i can connect to hive server
> through my laptop using JDBC and Squirrel SQL.
>
> Here are the hive logs :
>
> 2013-06-17 17:16:40,452 WARN  conf.HiveConf (HiveConf.java:<clinit>(75)) -
> hive-site.xml not found on CLASSPATH
> 2013-06-17 17:20:51,228 WARN  conf.HiveConf (HiveConf.java:<clinit>(75)) -
> hive-site.xml not found on CLASSPATH
> 2013-06-17 17:20:53,296 ERROR DataNucleus.Plugin
> (Log4JLogger.java:error(115)) - Bundle "org.eclipse.jdt.core" requires
> "org.eclipse.core.resources" but it cannot be resolved.
> 2013-06-17 17:20:53,296 ERROR DataNucleus.Plugin
> (Log4JLogger.java:error(115)) - Bundle "org.eclipse.jdt.core" requires
> "org.eclipse.core.resources" but it cannot be resolved.
> 2013-06-17 17:20:53,297 ERROR DataNucleus.Plugin
> (Log4JLogger.java:error(115)) - Bundle "org.eclipse.jdt.core" requires
> "org.eclipse.core.runtime" but it cannot be resolved.
> 2013-06-17 17:20:53,297 ERROR DataNucleus.Plugin
> (Log4JLogger.java:error(115)) - Bundle "org.eclipse.jdt.core" requires
> "org.eclipse.core.runtime" but it cannot be resolved.
> 2013-06-17 17:20:53,297 ERROR DataNucleus.Plugin
> (Log4JLogger.java:error(115)) - Bundle "org.eclipse.jdt.core" requires
> "org.eclipse.text" but it cannot be resolved.
> 2013-06-17 17:20:53,297 ERROR DataNucleus.Plugin
> (Log4JLogger.java:error(115)) - Bundle "org.eclipse.jdt.core" requires
> "org.eclipse.text" but it cannot be resolved.
> 2013-06-17 17:20:58,645 ERROR exec.Task (SessionState.java:printError(401))
> - FAILED: Error in metadata: InvalidObjectException(message:There is no
> database named themis)
> org.apache.hadoop.hive.ql.metadata.HiveException:
> InvalidObjectException(message:There is no database named themis)
>     at org.apache.hadoop.hive.ql.metadata.Hive.createTable(Hive.java:576)
>     at org.apache.hadoop.hive.ql.exec.DDLTask.createTable(DDLTask.java:3698)
>     at org.apache.hadoop.hive.ql.exec.DDLTask.execute(DDLTask.java:253)
>     at org.apache.hadoop.hive.ql.exec.Task.executeTask(Task.java:138)
>     at
> org.apache.hadoop.hive.ql.exec.TaskRunner.runSequential(TaskRunner.java:57)
>     at org.apache.hadoop.hive.ql.Driver.launchTask(Driver.java:1336)
>     at org.apache.hadoop.hive.ql.Driver.execute(Driver.java:1122)
>     at org.apache.hadoop.hive.ql.Driver.run(Driver.java:935)
>     at
> org.apache.hadoop.hive.cli.CliDriver.processLocalCmd(CliDriver.java:259)
>     at org.apache.hadoop.hive.cli.CliDriver.processCmd(CliDriver.java:216)
>     at org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:412)
>     at org.apache.hadoop.hive.cli.CliDriver.processLine(CliDriver.java:347)
>     at
> org.apache.hadoop.hive.cli.CliDriver.processReader(CliDriver.java:445)
>     at org.apache.hadoop.hive.cli.CliDriver.processFile(CliDriver.java:455)
>     at org.apache.hadoop.hive.cli.CliDriver.run(CliDriver.java:711)
>     at org.apache.hadoop.hive.cli.CliDriver.main(CliDriver.java:613)
>     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>     at
+
Jérôme Verdier 2013-06-17, 15:59
+
Jarek Jarcec Cecho 2013-06-17, 16:56
+
Jérôme Verdier 2013-06-18, 10:36
+
Venkat 2013-06-18, 13:38
+
Jérôme Verdier 2013-06-18, 14:02
+
Jérôme Verdier 2013-06-18, 14:14