Subject | Re: [firebird-support] BIGINT Vs Numeric(18,0) |
---|---|
Author | Daniel Rail |
Post date | 2004-04-16T10:41:02Z |
Hi,
At April 16, 2004, 05:31, Alan McDonald wrote:
I think the main importance of NUMERIC(18,0), is that the upper limit
is 999,999,999,999,999,999. If NUMERIC(19,0) would also be based on
BIGINT, the upper limit would be 9.223372*10^18.
And, imagine if you would have a field defined as NUMERIC(19,18), and
that the maximum value would be 9.223372... and not 9.999999999999....
I don't know if you notice what the problem could be, in terms of
maximum values accepted.
Although it would be possible to implement higher values than
NUMERIC(18,0), butit would require some work to get it working, since
it probably wouldn't be using OS or CPU native integer types. And,
that would have to be handled by FB.
--
Best regards,
Daniel Rail
Senior System Engineer
ACCRA Group Inc. (www.accra.ca)
ACCRA Med Software Inc. (www.filopto.com)
At April 16, 2004, 05:31, Alan McDonald wrote:
> We graduated from having to declare numeric(18,0) to declaring BIGINT.Forget what my previous message, my coffee just kicked in.
> Maybe a dumb question but can someone tell me why BIGINT actually takes 19
> places? how did we get another place or why wasn't it numeric(19,0)?
I think the main importance of NUMERIC(18,0), is that the upper limit
is 999,999,999,999,999,999. If NUMERIC(19,0) would also be based on
BIGINT, the upper limit would be 9.223372*10^18.
And, imagine if you would have a field defined as NUMERIC(19,18), and
that the maximum value would be 9.223372... and not 9.999999999999....
I don't know if you notice what the problem could be, in terms of
maximum values accepted.
Although it would be possible to implement higher values than
NUMERIC(18,0), butit would require some work to get it working, since
it probably wouldn't be using OS or CPU native integer types. And,
that would have to be handled by FB.
--
Best regards,
Daniel Rail
Senior System Engineer
ACCRA Group Inc. (www.accra.ca)
ACCRA Med Software Inc. (www.filopto.com)