You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@drill.apache.org by "James Turton (Jira)" <ji...@apache.org> on 2022/07/14 10:22:00 UTC

[jira] [Updated] (DRILL-7960) Column metadata DECIMAL precision can exceed max supported value

     [ https://issues.apache.org/jira/browse/DRILL-7960?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

James Turton updated DRILL-7960:
--------------------------------
    Summary: Column metadata DECIMAL precision can exceed max supported value  (was: VARDECIMAL(40, 6) exceeds maximum suppored precision of 38 - Union & query.json)

> Column metadata DECIMAL precision can exceed max supported value
> ----------------------------------------------------------------
>
>                 Key: DRILL-7960
>                 URL: https://issues.apache.org/jira/browse/DRILL-7960
>             Project: Apache Drill
>          Issue Type: Bug
>          Components: Client - HTTP
>    Affects Versions: 1.20.0
>         Environment: Drill in Docker
> Parquet Files with VARDECIMAL(29,6)
>  
>            Reporter: Nick Stenroos-Dam
>            Priority: Major
>
> We are using a lot of decimals in our data and keep running into issues.
> The latest issue is this error message:
> {code:java}
> SYSTEM ERROR: Drill Remote Exception
> Please, refer to logs for more information.
>  (java.lang.IllegalArgumentException) VARDECIMAL(40, 6) exceeds maximum suppored precision of 38
>  org.apache.drill.exec.record.metadata.MetadataUtils.newDecimal():228
>  org.apache.drill.exec.record.metadata.MetadataUtils.fromField():66
>  org.apache.drill.exec.physical.resultSet.model.single.SingleSchemaInference.inferVector():86
>  org.apache.drill.exec.physical.resultSet.model.single.SingleSchemaInference.infer():64
>  org.apache.drill.exec.physical.rowSet.DirectRowSet.fromContainer():80
>  org.apache.drill.exec.physical.resultSet.impl.PushResultSetReaderImpl.createRowSet():100
>  org.apache.drill.exec.physical.resultSet.impl.PushResultSetReaderImpl.start():85
>  org.apache.drill.exec.server.rest.stream.StreamingHttpConnection.sendData():116
>  org.apache.drill.exec.ops.AccountingUserConnection.sendData():43
>  org.apache.drill.exec.physical.impl.ScreenCreator$ScreenRoot.innerNext():106
>  org.apache.drill.exec.physical.impl.BaseRootExec.next():93
>  org.apache.drill.exec.work.fragment.FragmentExecutor$1.run():323
>  org.apache.drill.exec.work.fragment.FragmentExecutor$1.run():310
>  .......():0
>  org.apache.hadoop.security.UserGroupInformation.doAs():1762
>  org.apache.drill.exec.work.fragment.FragmentExecutor.run():310
>  org.apache.drill.common.SelfCleaningRunnable.run():38
>  .......():0
> {code}
> I have now been able to reproduce the issue. 
>  Apparently the issue only occurs when using the Web API (query.json) and not the Web interface.
> To reproduce the issue run
> {code:java}
> curl -X POST http://localhost:8047/query.json -d '{ "queryType": "SQL", "query": "SELECT CAST(10 AS DECIMAL(38, 4)) AS `Col1`\nUNION ALL \nSELECT CAST(22 AS DECIMAL(29, 6)) AS `Col1`", "autoLimit": null, "defaultSchema": "data" }' -H 'Content-Type: application/json'{code}
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)