Quote:

>I'm getting a math error in Access. It appears to be a problem in

>A97, A2000, and AccessXP.

>1. Go to an immediate window

>2. Type the following expression:

> ? INT( 100000 * 4.1)

>The answer I get every time is: 409999

>Unless I'm mistaken, the answer should be 410000

>Does anyone see a problem with this?

Only a problem with expectation.

Floating point numbers, such as 4.1, are stored internally as binary

fractions times an exponent. As such, they are approximations (just as

3.1415926535 is an approximation to pi, or 0.142856 is an

approximation to 1/7).

The Int() function is rounding down. The stored approximation to 4.1

is evidently just a tiny bit less than 4.1, and the rounding is biting

you.

John W. Vinson[MVP]

Come for live chats every Tuesday and Thursday

http://go.compuserve.com/msdevapps?loc=us&access=public