Rounding off of figures

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Just created a great database but when I imput some data in Access rounds it
off to zero decimal places. Re-examined everything but can not see why it is
doing this. ANY IDEAS?
Thanks,
Graham
 
Open the table in design view.
Select the Number field.
In the lower pane, change the Field Size to Double.

The Integer types store whole numbers only.
 
Most common cause is forgetting to change the Field Size of the field from
the default Long Integer when you created the field. Only the Single and
Double sizes can accept decimal points.
 
What is the datatype of the Access field? Is it Number, Integer? If so, an
integer is a whole number. You would need to use Single, Double, or Currency
based on your requirement for precission.
 
.... and decimal, but note that the decimal datatype is bit broken.

Or use the currency datatype.
 
Pieter said:
AKA buggy as hell

<Sighs> Here we go again...

This week's the DECIMAL data type is worthy of consideration.

Engine sorting of negative values in descending order (honestly, just
how many people need to do this?) is predictable yet wrong. Resolution:
don't sort using the engine or create an additional column for sorting
purposes by efficiently promoting the DECIMAL column to another data
type.

Jet's CDEC casting function is broken but is not a major issue: Jet
considers decimal values to be native DECIMAL in nature; the CDEC
function can be implemented in VBA in Access; values in Jet can be
coerced to DECIMAL by operating on them using native DECIMAL value.

VBA has a Decimal variant subtype which is acceptable (and is numeric
<g>): a multiple-scaled integer needed to implemented as a reference
type; fixed point types have no hardware support so the inefficiency
associated with the Variant type would still be an issue if Decimal was
an intrinsic type; not all native Jet types map directly to a VBA type
and where they do they are not always widely used (e.g. CHAR(N) maps to
String * N).

The export bug can be worked around (and improved upon) using a
different export approach e.g. a query.

Anything else?

Jamie.

--
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top