sqoop-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Anson Abraham <anson.abra...@gmail.com>
Subject Sqoop import postgres schema
Date Tue, 29 Nov 2011 22:55:39 GMT
I'm having issues executing sqoop import function.

i'm trying to run sqoop to import at least one table into hdfs.  But the
table exists in a schema that is not public.
So example:

sqopp import --connect jdbc:postgresql://host/dbname --username test
-target-dir /path/to/hdfs --table myschema.employee
does not work.  I get an error of:

11/11/29 22:48:31 INFO manager.SqlManager: Executing SQL statement: SELECT
t.* FROM "myschema.employee" AS t LIMIT 1
11/11/29 22:48:31 ERROR manager.SqlManager: Error executing statement:
org.postgresql.util.PSQLException: ERROR: relation "myschema.employee" does
not exist
  Position: 17
org.postgresql.util.PSQLException: ERROR: relation "myschema.employee" does
not exist

 Position: 17
at
org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2103)
at
org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1836)
 at
org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:257)
at
org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:512)
 at
org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:388)
at
org.postgresql.jdbc2.AbstractJdbc2Statement.executeQuery(AbstractJdbc2Statement.java:273)
 at org.apache.sqoop.manager.SqlManager.execute(SqlManager.java:487)
at org.apache.sqoop.manager.SqlManager.execute(SqlManager.java:496)
 at
org.apache.sqoop.manager.SqlManager.getColumnTypesForRawQuery(SqlManager.java:194)
at org.apache.sqoop.manager.SqlManager.getColumnTypes(SqlManager.java:178)
 at
org.apache.sqoop.manager.ConnManager.getColumnTypes(ConnManager.java:114)
at org.apache.sqoop.orm.ClassWriter.getColumnTypes(ClassWriter.java:1224)
 at org.apache.sqoop.orm.ClassWriter.generate(ClassWriter.java:1049)
at org.apache.sqoop.tool.CodeGenTool.generateORM(CodeGenTool.java:82)
 at org.apache.sqoop.tool.ImportTool.importTable(ImportTool.java:368)
at org.apache.sqoop.tool.ImportTool.run(ImportTool.java:454)
 at org.apache.sqoop.Sqoop.run(Sqoop.java:145)
at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:65)
 at org.apache.sqoop.Sqoop.runSqoop(Sqoop.java:181)
at org.apache.sqoop.Sqoop.runTool(Sqoop.java:220)
 at org.apache.sqoop.Sqoop.runTool(Sqoop.java:229)
at org.apache.sqoop.Sqoop.main(Sqoop.java:238)
 at com.cloudera.sqoop.Sqoop.main(Sqoop.java:57)


Can sqoop support importing from schema's?

Mime
View raw message