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

Jarek Jarcec Cecho commented on SQOOP-2612:
-------------------------------------------

I see a value in having ability to map entire type to something else rather 
then individual columns. In fact my original patch that added 
{{\-\-map\-column\-java}} has that functionality back in SQOOP-342, but it 
wasn't committed as the community felt that it won't be much helpful at the 
time. I feel that this changed as I see many people struggling with the 
mapping, so I'm +1 on adding that functionality.

It seems that the column mapping is primarily implemented in {{ClassWriter}} 
class - any reason why the type based mapping is implemented elsewhere  
[~proftodd]? I'm concerned that it will be confusing to maintain when very 
similar functionality is twice on different places.

> Allow rules-based column mapping
> --------------------------------
>
>                 Key: SQOOP-2612
>                 URL: https://issues.apache.org/jira/browse/SQOOP-2612
>             Project: Sqoop
>          Issue Type: New Feature
>          Components: codegen, connectors, test, tools
>    Affects Versions: 1.4.6
>            Reporter: John Todd
>            Priority: Minor
>         Attachments: SQOOP-2612.patch
>
>
> Allow users to map source columns to Java and Avro types based on rules 
> rather than a list.
> About half the data types on my current project are NUMERIC, and many of 
> those have a SCALE of 0. It would be helpful to be able to process those as 
> Integers or Longs. The map-column-java feature is helpful, but it requires 
> continuous surveillance of the source tables and maintenance of lists of 
> columns and what type they should be mapped to.
> It would be helpful to be able to create a rules-based interpretation of the 
> type inference provided by Sqoop.



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

Reply via email to