That's pretty much what I thought. Thanks for the information.
On a side note, is it possible to specify an alternate Java type in the
modeler for an ObjEntity attribute? In our old EOF model, we have many
instances of a custom data type (MOFixed[1-6] which is an integer in the
database) that I'd like to try to replicate if possible. For example, a
MOFixed3 represents 6.875 as 6875 in the database ... I thought at
first I could just subclass java.lang.Integer, but they made it a final
class (gotta love Java).
Thanks,
/dev/mrg
-----Original Message-----
From: Andrus Adamchik [mailto:andru..bjectstyle.org]
Sent: Wednesday, December 01, 2004 5:01 PM
To: cayenne-use..bjectstyle.org
Subject: Re: Precision = Scale?
> In the Cayenne Modeler, under DbEntity/Attributes, does the
"Precision"
> column equal the scale for a DECIMAL? For example, if you have a
> DECIMAL(12,2) is the "Max Length" = 12 and the "Precision" = 2? If
so,
> can the maximum length be omitted?
>
> Thanks,
>
> /dev/mrg
Yeah, the naming is somewhat unfortunate (we may need to change this in
the future)... Precision is really decimal scale. For DECIMAL columns
schema generation purposes if max length is not set, precision
(umm...scale) is ignored.
Andrus
This archive was generated by hypermail 2.0.0 : Wed Dec 01 2004 - 18:16:13 EST