You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sqoop.apache.org by "Anna Szonyi (JIRA)" <ji...@apache.org> on 2017/04/07 11:54:41 UTC

[jira] [Commented] (SQOOP-3168) Sqoop Saved Job feature of overwriting job argument at execution time is not working in Sqoop1.4.6CDH 5.8.0

    [ https://issues.apache.org/jira/browse/SQOOP-3168?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15960653#comment-15960653 ] 

Anna Szonyi commented on SQOOP-3168:
------------------------------------

Hi,

Unfortunately this is a bug that was introduced with SQOOP-2779 and later fixed by SQOOP-2896. As for a workaround: there is none, besides patching it with the fix of SQOOP-2896, as for CDH 5.8.0, only creating new jobs or upgrading to 5.8.5+ would solve it, as that is where the fix was first backported.

Apologies and Regards,
Anna

> Sqoop Saved Job feature of overwriting job argument at execution time is not working in Sqoop1.4.6CDH 5.8.0
> -----------------------------------------------------------------------------------------------------------
>
>                 Key: SQOOP-3168
>                 URL: https://issues.apache.org/jira/browse/SQOOP-3168
>             Project: Sqoop
>          Issue Type: Bug
>            Reporter: Hemendra Yadav
>
> Hi,
> I have created one sqoop saved job using below command ::
> sqoop job --create <job_name> -- import --connect <url> --driver com.mysql.jdbc.Driver --username <username> --password <password> --table <table> --target-dir location1 --fields-terminated-by , --escaped-by \\ -m 1
>  
> I need to put the data to different location so while execution i have provided new location in below command::
> sqoop job --exec jobname1 -- --target-dir location_new
>  But it still picks up the target directory from the saved job i.e. location1.
> I am currently using sqoop 1.4.6 CDH 5.8.0 version. When i have checked the sqoop code it seems that in sqoop CDH 5.8.0  code for overwritting job argument is removed from the method "private int execJob(SqoopOptions opts)" in the class "org.apache.sqoop.tool.JobTool" due to issue "https://issues.apache.org/jira/browse/SQOOP-2779".
>  When i have executed the same command using sqoop 1.4.6 CDH 5.7.3 it is able to overwrite the target directory and working as expected.
> Can you please suggest any workaround how to import data to a different target directory while executing sqoop saved job.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)