openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rick Curtis <>
Subject Re: Why not OpenJPA map BigDecimal to NUMERIC(precision, scale) on database support NUMERIC
Date Tue, 16 Oct 2012 16:35:20 GMT
I looked back through my emails from when I backed this change out and
can't figure out which test I regressed. The reason that I backed the
change out rather than fix the problem is because we were in the middle of
trying to cut a release. I'll open a new JIRA soon here and just recommit
the change to trunk for Derby / DB2 and fix the bug(s) when it rolls in.

> Is there any reason to ignore (precision, scale) of numeric on postgres?
If I made the change for postgres, is this something you would be able to


On Fri, Oct 12, 2012 at 9:08 PM, Yaocl <> wrote:

> Hi
> I use postgres in production environment, when using MappingTool to
> generate DDL, I found openjpa map BigDecimal to NUMERIC but ignored
> precision and scale specified in @Column.
> When use openjpa with mysql. It can generate NUMERIC(precision,
> scale). Finally I found because DBDictionary added NUMERIC into
> fixedSizeTypeNameSet. So postgres not generate (precision, scale).
> MySQLDictionary and SybaseDictionary removed NUMERIC from
> fixedSizeTypeNameSet and these two database support (precision,
> scale).
> I haven't view all Dictionary class. Is there any reason to ignore
> (precision, scale) of numeric on postgres? I known the postgres
> database support NUMERIC(precision, scale) data type.
> When use openjpa with  DB2 and Derby. It use DOUBLE for BigDecimal,
> Because numericTypeName defined to DOUBLE in AbstractDB2Dictionary.
> <> tried to fix it,
> but finally
> backed out changes because a test regression. DOUBLE cannot represent
> decimal fractions exactly. Maybe we should consider to change it to
> Regards,
> YaoCL

*Rick Curtis*

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message