[ https://issues.apache.org/jira/browse/SQOOP-3418?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16718788#comment-16718788 ]
ASF GitHub Bot commented on SQOOP-3418: --------------------------------------- Github user fszabo2 commented on a diff in the pull request: https://github.com/apache/sqoop/pull/66#discussion_r240969163 --- Diff: src/docs/user/import.txt --- @@ -838,20 +850,27 @@ $ sqoop import --connect jdbc:mysql://db.foo.com/corp \ ---- Enabling logical types in avro import and also turning on padding with 0s: - ---- $ sqoop import -Dsqoop.avro.decimal_padding.enable=true -Dsqoop.avro.logical_types.decimal.enable=true - --connect $CON --username $USER --password $PASS --query "select * from table_name where \$CONDITIONS" + --connect $MYCONN --username $MYUSER --password $MYPASS --query "select * from table_name where \$CONDITIONS" --target-dir hdfs://nameservice1//etl/target_path --as-avrodatafile --verbose -m 1 ---- Enabling logical types in avro import and also turning on padding with 0s, while specifying default precision and scale as well: - ---- $ sqoop import -Dsqoop.avro.decimal_padding.enable=true -Dsqoop.avro.logical_types.decimal.enable=true -Dsqoop.avro.logical_types.decimal.default.precision=38 -Dsqoop.avro.logical_types.decimal.default.scale=10 - --connect $CON --username $USER --password $PASS --query "select * from table_name where \$CONDITIONS" + --connect $MYCONN --username $MYUSER --password $MYPASS --query "select * from table_name where \$CONDITIONS" --target-dir hdfs://nameservice1//etl/target_path --as-avrodatafile --verbose -m 1 ---- + +Enabling logical types in parquet import and also turning on padding with 0s, while specifying default precision and scale as well: +---- +$ sqoop import -Dsqoop.parquet.decimal_padding.enable=true -Dsqoop.avro.logical_types.decimal.enable=true --- End diff -- Yes! > Document decimal support in Hive external import into parquet files > ------------------------------------------------------------------- > > Key: SQOOP-3418 > URL: https://issues.apache.org/jira/browse/SQOOP-3418 > Project: Sqoop > Issue Type: Task > Reporter: Fero Szabo > Assignee: Fero Szabo > Priority: Major > Fix For: 1.5.0, 3.0.0 > > > Remember to note the limitations in Hive i.e. the max scale and precision is > 38 and how it behaves in edge cases. -- This message was sent by Atlassian JIRA (v7.6.3#76005)