sqoop-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bhavesh Shah <bhavesh25s...@gmail.com>
Subject Error while sqoop-export
Date Tue, 13 Mar 2012 06:28:03 GMT
Hello,
Previously I had imported many tables from SQL Server in Hive. I have
worked on those tables and finally create a table named as tempmeasure and
I want to export it in SQL Server back.
But doing this I am getting error as:

*hadoop@ubuntu:~/sqoop-1.3.0-cdh3u1/bin$ ./sqoop-export --connect
'jdbc:sqlserver://192.168.xx.xx;username=xxx;password=xxxxxx;database=HadoopTest'
--table tempmeasure --export-dir /user/hive/warehouse/tempmeasure/*
12/03/12 20:46:01 INFO SqlServer.MSSQLServerManagerFactory: Using
Microsoft's SQL Server - Hadoop Connector
12/03/12 20:46:01 INFO manager.SqlManager: Using default fetchSize of 1000
12/03/12 20:46:01 INFO tool.CodeGenTool: Beginning code generation
12/03/12 20:46:02 INFO manager.SqlManager: Executing SQL statement: SELECT
TOP 1 * FROM [tempmeasure]
12/03/12 20:46:02 ERROR manager.SqlManager: Error executing statement:
com.microsoft.sqlserver.jdbc.SQLServerException: Invalid object name
'tempmeasure'.
com.microsoft.sqlserver.jdbc.SQLServerException: Invalid object name
'tempmeasure'.
    at
com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(SQLServerException.java:197)
    at
com.microsoft.sqlserver.jdbc.SQLServerStatement.getNextResult(SQLServerStatement.java:1493)
    at
com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.doExecutePreparedStatement(SQLServerPreparedStatement.java:390)
    at
com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement$PrepStmtExecCmd.doExecute(SQLServerPreparedStatement.java:340)
    at com.microsoft.sqlserver.jdbc.TDSCommand.execute(IOBuffer.java:4575)
    at
com.microsoft.sqlserver.jdbc.SQLServerConnection.executeCommand(SQLServerConnection.java:1400)
    at
com.microsoft.sqlserver.jdbc.SQLServerStatement.executeCommand(SQLServerStatement.java:179)
    at
com.microsoft.sqlserver.jdbc.SQLServerStatement.executeStatement(SQLServerStatement.java:154)
    at
com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.executeQuery(SQLServerPreparedStatement.java:283)
    at com.cloudera.sqoop.manager.SqlManager.execute(SqlManager.java:471)
    at com.cloudera.sqoop.manager.SqlManager.execute(SqlManager.java:480)
    at
com.cloudera.sqoop.manager.SqlManager.getColumnTypesForRawQuery(SqlManager.java:193)
    at
com.cloudera.sqoop.manager.SqlManager.getColumnTypes(SqlManager.java:177)
    at
com.cloudera.sqoop.orm.ClassWriter.getColumnTypes(ClassWriter.java:1185)
    at com.cloudera.sqoop.orm.ClassWriter.generate(ClassWriter.java:1027)
    at com.cloudera.sqoop.tool.CodeGenTool.generateORM(CodeGenTool.java:82)
    at com.cloudera.sqoop.tool.ExportTool.exportTable(ExportTool.java:64)
    at com.cloudera.sqoop.tool.ExportTool.run(ExportTool.java:110)
    at com.cloudera.sqoop.Sqoop.run(Sqoop.java:144)
    at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:65)
    at com.cloudera.sqoop.Sqoop.runSqoop(Sqoop.java:180)
    at com.cloudera.sqoop.Sqoop.runTool(Sqoop.java:219)
    at com.cloudera.sqoop.Sqoop.runTool(Sqoop.java:228)
    at com.cloudera.sqoop.Sqoop.main(Sqoop.java:237)
12/03/12 20:46:02 INFO manager.SqlManager: Executing SQL statement: SELECT
TOP 1 * FROM [tempmeasure]
12/03/12 20:46:02 ERROR manager.SqlManager: Error executing statement:
com.microsoft.sqlserver.jdbc.SQLServerException: Invalid object name
'tempmeasure'.
com.microsoft.sqlserver.jdbc.SQLServerException: Invalid object name
'tempmeasure'.
    at
com.microsoft.sqlserver.jdbc.SQLServerException.makeFromDatabaseError(SQLServerException.java:197)
    at
com.microsoft.sqlserver.jdbc.SQLServerStatement.getNextResult(SQLServerStatement.java:1493)
    at
com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.doExecutePreparedStatement(SQLServerPreparedStatement.java:390)
    at
com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement$PrepStmtExecCmd.doExecute(SQLServerPreparedStatement.java:340)
    at com.microsoft.sqlserver.jdbc.TDSCommand.execute(IOBuffer.java:4575)
    at
com.microsoft.sqlserver.jdbc.SQLServerConnection.executeCommand(SQLServerConnection.java:1400)
    at
com.microsoft.sqlserver.jdbc.SQLServerStatement.executeCommand(SQLServerStatement.java:179)
    at
com.microsoft.sqlserver.jdbc.SQLServerStatement.executeStatement(SQLServerStatement.java:154)
    at
com.microsoft.sqlserver.jdbc.SQLServerPreparedStatement.executeQuery(SQLServerPreparedStatement.java:283)
    at com.cloudera.sqoop.manager.SqlManager.execute(SqlManager.java:471)
    at com.cloudera.sqoop.manager.SqlManager.execute(SqlManager.java:480)
    at
com.cloudera.sqoop.manager.SqlManager.getColumnNamesForRawQuery(SqlManager.java:128)
    at
com.cloudera.sqoop.manager.SqlManager.getColumnNames(SqlManager.java:112)
    at
com.cloudera.sqoop.orm.ClassWriter.getColumnNames(ClassWriter.java:1154)
    at com.cloudera.sqoop.orm.ClassWriter.generate(ClassWriter.java:1029)
    at com.cloudera.sqoop.tool.CodeGenTool.generateORM(CodeGenTool.java:82)
    at com.cloudera.sqoop.tool.ExportTool.exportTable(ExportTool.java:64)
    at com.cloudera.sqoop.tool.ExportTool.run(ExportTool.java:110)
    at com.cloudera.sqoop.Sqoop.run(Sqoop.java:144)
    at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:65)
    at com.cloudera.sqoop.Sqoop.runSqoop(Sqoop.java:180)
    at com.cloudera.sqoop.Sqoop.runTool(Sqoop.java:219)
    at com.cloudera.sqoop.Sqoop.runTool(Sqoop.java:228)
    at com.cloudera.sqoop.Sqoop.main(Sqoop.java:237)
12/03/12 20:46:02 ERROR sqoop.Sqoop: Got exception running Sqoop:
java.lang.NullPointerException
java.lang.NullPointerException
    at
com.cloudera.sqoop.orm.ClassWriter.cleanColNames(ClassWriter.java:1012)
    at com.cloudera.sqoop.orm.ClassWriter.generate(ClassWriter.java:1033)
    at com.cloudera.sqoop.tool.CodeGenTool.generateORM(CodeGenTool.java:82)
    at com.cloudera.sqoop.tool.ExportTool.exportTable(ExportTool.java:64)
    at com.cloudera.sqoop.tool.ExportTool.run(ExportTool.java:110)
    at com.cloudera.sqoop.Sqoop.run(Sqoop.java:144)
    at org.apache.hadoop.util.ToolRunner.run(ToolRunner.java:65)
    at com.cloudera.sqoop.Sqoop.runSqoop(Sqoop.java:180)
    at com.cloudera.sqoop.Sqoop.runTool(Sqoop.java:219)
    at com.cloudera.sqoop.Sqoop.runTool(Sqoop.java:228)
    at com.cloudera.sqoop.Sqoop.main(Sqoop.java:237)
hadoop@ubuntu:~/sqoop-1.3.0-cdh3u1/bin$

Pls help me out. Is anything wrong with me?
(My Hadoop Version - hadoop-0.20.2cdh3
 Hive - hive-0.7.1
  and Sqoop - sqoop-1.3.0-cdh3u1)



-- 
Thanks and Regards,
Bhavesh Shah

Mime
View raw message