Home Forums Sqoop Unable to sqoop data from HDFS to Oracle

This topic contains 3 replies, has 1 voice, and was last updated by  Faisal ahmed Siddiqui 9 months ago.

  • Creator
    Topic
  • #30046

    Hi ,
    I am trying to export a file on HDFS to Oracle database using sqoop and getting following error.
    here is my command.
    ———————
    sqoop export –connect jdbc:oracle:thin:@host:port:SID –username xxxxxx –password xxxxxxx –export-dir /user/faisals/examples/output-data/ –table sqoop_test –input-fields-terminated-by ’001′ –driver oracle.jdbc.driver.OracleDriver –verbose
    ———————-
    13/07/25 14:51:53 WARN sqoop.ConnFactory: Parameter –driver is set to an explicit driver however appropriate connection manager is not being set (via –connection-manager). Sqoop is going to fall back to org.apache.sqoop.manager.GenericJdbcManager. Please specify explicitly which connection manager should be used next time.
    13/07/25 14:51:53 INFO manager.SqlManager: Using default fetchSize of 1000
    13/07/25 14:51:53 INFO tool.CodeGenTool: Beginning code generation
    13/07/25 14:51:53 DEBUG manager.SqlManager: No connection paramenters specified. Using regular API for making connection.
    13/07/25 14:51:53 DEBUG manager.SqlManager: Using fetchSize for next query: 1000
    13/07/25 14:51:53 INFO manager.SqlManager: Executing SQL statement: SELECT t.* FROM sqoop_test AS t WHERE 1=0
    13/07/25 14:51:53 ERROR manager.SqlManager: Error executing statement: java.sql.SQLException: ORA-00933: SQL command not properly ended

    java.sql.SQLException: ORA-00933: SQL command not properly ended
    ———————-
    As we can see, sqoop generating a wrong SQL for oracle database not where to drill further.
    In addition, how does sqoop identified column mapping. lik e file on HDFS first column map to abc column in oracle etc?
    Highly appreciate your help..

    Thanks
    Faisal

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Unable to sqoop data from HDFS to Oracle’ is closed to new replies.

  • Author
    Replies
  • #30109

    wow this issue is resolved if we remove –driver argument..
    In addition, always mention user and tables upper case to avoid subsequent error
    Have fun :)
    Faisal

    Collapse
    #30054

    Here is my sqoop version: Sqoop 1.4.3.1.3.0.0-107

    Collapse
    #30048

    here is my oracle version & java driver.
    ————
    Oracle Database 11g Enterprise Edition Release 11.1.0.7.0 – 64bit Production
    ————-
    ojdbc14_g.jar
    Note: this driver is working fine with the database from my local machine. and i have placed it under SQOOP_HOME/lib folder i,e. /usr/lib/sqoop/lib

    Collapse
Viewing 3 replies - 1 through 3 (of 3 total)