RE: access.query.overflow
- From: "clara39" <clara39@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Wed, 15 Jun 2005 08:16:11 -0700
thanks. it turns out i was dividing by zero in some cases. I took out the
zero fields. the other information is good to know!
"Ted Allen" wrote:
> Hi,
>
> A couple of things can cause this, but both of them are similar in that the
> result is exceeding the capacity of the data type. Probably the most common
> cause is dividing by 0, which gives an infinite result that causes the
> overflow error. The other cause is having calculations that return a result
> beyond the capacity of the field size. In your case, if you are not dividing
> by zero, it is possible that the field size is only integer, which can only
> hold values up to 32,767. If you formula results in any values greater than,
> or less than, the field size, you will get an overflow error.
>
> When calculating fields in an Access query, Access (or Jet?) sets the field
> type/size by looking at the formula. Often though, this field size is not
> adequate. You can set the field output size and type by using the various
> type conversion functions though. For instance, if you put your formula
> inside of the CLng() function, the resulting field will be a long integer.
> Similarly, if you use CDbl(), the output will be a double precision floating
> point decimal field.
>
> HTH, Ted Allen
>
> "clara39" wrote:
>
> > I am trying to run a select query that sums a formula like a/b*c. i get an
> > overflow message. How do i avoid this message. "rounding" did not help.
.
- References:
- access.query.overflow
- From: clara39
- RE: access.query.overflow
- From: Ted Allen
- access.query.overflow
- Prev by Date: Union Query Problem
- Next by Date: RE: compare fields
- Previous by thread: RE: access.query.overflow
- Next by thread: Multiple INNER JOIN statements
- Index(es):
Relevant Pages
|