Decimal number field

goodfu

Registered User.
Local time
Today, 17:11
Joined
Dec 23, 2010
Messages
140
If you specify Number as data type and Decimal as field size for a field in an Access table, will it actually store numbers to the right of the decimal point? I have never been able to get this to work or find these value if they are there and have alwayshad to use field size single or double or data type currency.
 
As you have discovered, you need to use single, double or Currency.
 
Perhaps if you describe how your set "Decimal as field size ", we may be able to describe what is really happening.
 
Decimal requires the Precision and Scale properties to be adjusted. Scale is the number of places after the decimal point. The default is zero which is why you have experienced the problem.

It is stored as an integer with a scaling factor and handles a maximum of 28 digits (Precision).

It is able to accurately represent numbers with fractional components which would be subjected to rounding errors if stored as a Single or Double due to the nature of storing base ten numbers in binary.

Currency is similar to Decimal with a fixed Scale of 4 and Precision of 19.
 
The default is auto. I have tried using 2 and could not get that to work.

I don't see a precision property.
 
You must be looking at one of the other number types.

Change the Field Size to Decimal and the Precision and Scale properties should appear.
 
Okay. You have to enter something for Scale or it won't work. I've been wondering about that for a long time. Seems redundant if you enter a value in Decimal but whatever. Thanks.
 
And I learned something about the new Decimal Data Type. Thanks guys.
 

Users who are viewing this thread

Back
Top Bottom