You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sqoop.apache.org by "Paul Mazak (JIRA)" <ji...@apache.org> on 2015/05/01 19:52:06 UTC

[jira] [Commented] (SQOOP-1171) Add possibility to specify columns list to export in required table.

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

Paul Mazak commented on SQOOP-1171:
-----------------------------------

I recommend this issue be closed because SQOOP-503 was committed.  I validated that this scenario works with Text data in HDFS exporting to SQL Server.
{quote}
    Target table contains the following fields: id, message, country. 'id' is auto-increment / identity column. 
    Only two columns on HDFS (message and country). 
    Using the '--columns message, country' during export, the table performs the inserts and the first column is auto-incremented.
{quote}
Since this worked for me, what were the conditions it failed for [~kostiantyn]?  Were you using Text or a different data format in HDFS?  Which target database were you exporting to?  I am aware this will not work for Avro data in HDFS, but that will be addressed by issue SQOOP-1369.

> Add possibility to specify columns list to export in required table.
> --------------------------------------------------------------------
>
>                 Key: SQOOP-1171
>                 URL: https://issues.apache.org/jira/browse/SQOOP-1171
>             Project: Sqoop
>          Issue Type: Bug
>            Reporter: Kostiantyn Kudriavtsev
>              Labels: patch
>         Attachments: columns_to_export.patch
>
>   Original Estimate: 24h
>  Remaining Estimate: 24h
>
> Add possibility to specify columns list to export in required table.
> For example, your target table contains the following fields: id, message, country, dtx. 'id' is autoincrement field and 'dtx' set by trigger. So, you have only two columns on HDFS (message and country). Now you can set them w/ option '--columns message, country' during export



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)