You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@calcite.apache.org by Mehant Baid <ba...@gmail.com> on 2014/06/19 08:19:24 UTC
Maximum scale and precision for numeric data
Hey,
Currently the max scale and precision for numeric data types is 19
(defined here
<https://github.com/julianhyde/optiq/blob/master/core/src/main/java/org/eigenbase/sql/type/SqlTypeName.java#L90>).
In Drill maximum precision and scale is 38, so I was hitting a case
where Optiq is trying to insert casts to cap the precision to be 19. Are
other projects outside Optiq depending on this limit, if so can we make
it configurable? If not, I was able to modify the max to be 38 and
although I hit a few failing test but most of them were straight forward
to fix.
Thanks
Mehant
Re: Maximum scale and precision for numeric data
Posted by Julian Hyde <ju...@hydromatic.net>.
You are welcome to make it configurable -- but please log a JIRA case proposing a smart way to do it. If you, say, just add it to some properties file you'll have end-users wondering whether they can change it.
Julian
On Jun 18, 2014, at 11:19 PM, Mehant Baid <ba...@gmail.com> wrote:
> Hey,
>
> Currently the max scale and precision for numeric data types is 19 (defined here <https://github.com/julianhyde/optiq/blob/master/core/src/main/java/org/eigenbase/sql/type/SqlTypeName.java#L90>). In Drill maximum precision and scale is 38, so I was hitting a case where Optiq is trying to insert casts to cap the precision to be 19. Are other projects outside Optiq depending on this limit, if so can we make it configurable? If not, I was able to modify the max to be 38 and although I hit a few failing test but most of them were straight forward to fix.
>
> Thanks
> Mehant