Re: Currency Datatype Really Good to Use For Non-currency Fields?
- From: tbl <hate@xxxxxxxxxxxx>
- Date: Thu, 06 Jul 2006 06:01:05 -0700
On Thu, 6 Jul 2006 13:04:09 +0800, "Allen Browne"
<AllenBrowne@xxxxxxxxxxxxxx> wrote:
Currency has the advantage that it is a fixed point number (exactly 4
decimal places.) That means it has none of the rounding issues inherent in
floating point types (Single and Double.) It is therfore ideal for number
that must include a fractional part, but where you don't want rounding or
matching errors.
For example, you could use it to store distances in metres, provided you
don't need anything smaller than one tenth of a metre.
Disadvantages:
a. Cannot handle minute or enormous values the way floating point fields
can.
b. According to the documentation, it may be slower to calculate, though I
have not observed this.
c. You need to specify the Format, so it does not display as currency.
Access 2000 introduced the Decimal type: a scalar number where you can
specify the number of decimal places. Unfortunately, it is not correctly
implemented, so even a basic sort fails, so I suggest you don't use this
type. Details:
http://allenbrowne.com/bug-08.html
Thanks Allen. Your information gives my confidence a boost.
It seems that the currency datatype should do just fine for
some of my fields.
--
tbl
.
- References:
- Prev by Date: RE: table design and relationships
- Next by Date: Re: how to create funeral program
- Previous by thread: Re: Currency Datatype Really Good to Use For Non-currency Fields?
- Next by thread: Re: Currency Datatype Really Good to Use For Non-currency Fields?
- Index(es):
Relevant Pages
|