Liwei Lin created PARQUET-484:
---------------------------------

             Summary: Add precision, scale compatibility check for 
DecimalMetadata
                 Key: PARQUET-484
                 URL: https://issues.apache.org/jira/browse/PARQUET-484
             Project: Parquet
          Issue Type: Improvement
          Components: parquet-mr
    Affects Versions: 1.8.0, 1.8.1
            Reporter: Liwei Lin
            Assignee: Liwei Lin


We have some constrains for the Decimal type's precision and scale, as is 
documented in 
https://github.com/Parquet/parquet-format/blob/master/LogicalTypes.md:

int32: for 1 <= precision <= 9
int64: for 1 <= precision <= 18; precision < 10 will produce a warning

This JIRA proposes to implements the constrains, specifically:

Throws Exception when any of the following does not hold:
- precision > 0 && scale >= 0
- precision >= scale
- for int32, precision <= 9
- for int64, precision <= 18

Throws an Warning when:
- for int64, precision < 10




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

Reply via email to