NUMBERS IN A TABLE

  • Thread starter Thread starter chris morrison
  • Start date Start date
C

chris morrison

I have some experience in using databases, but for the
life of me I cannot understand why Access makes you jump
thru so many hoops to do a simple procedure. All I want to
do is set up a number field in my table called rate. I
want to be able to type in 2.87 and have it stay (and
display) 2.87, not 2.0 or 2.00? How can I make this happen?
 
Chris,

There are a number of different types of numbers that can be used in an
Access (or other) database, and they are represented by choices in the
FieldSize property of the particular number field in your table. The
default FieldSize for Number data types is Long Integer, which does not
display decimals The most frequently used of these are (from Access Help):
Integer, Long Integer, Single and Double.

For your purposes, you probably will want to change the FieldSize property
of your number field to Single or Double. Also, there is a Currency data
type, which is used to store money values.
 
Open your table in design view. Click at your field, and then F6 - this will
switch the panes and you will able to change the Field properties.
Then change he Field size to Single, the format propery to General Number
and the Decimal Places to 2 or more.
If your file size was Long Integer (I thing that is the default value)
Access will round the number to be Integer - without decimal places.
 
Hi

The default field type can be changed in Tools - Options - Tables/Queries, e.g. Double or Text

Bernd
 
Marin Kostov said:
Open your table in design view. Click at your field, and then F6 - this will
switch the panes and you will able to change the Field properties.
Then change he Field size to Single, the format propery to General Number
and the Decimal Places to 2 or more.
If your file size was Long Integer (I thing that is the default value)
Access will round the number to be Integer - without decimal places.
 
I think it is something to do with which number format you
pick when you set up the field in the table. Open the
Table in Design mode, go to the field and check what
number format it is - there are several. I can't remember
exactly which one you need, so try different ones. I am
also not sure that you can do a similar thing in Forms. I
had the same problem a few years ago. Stick with Access -
it is brilliant!
 
Back
Top