Results 1 to 3 of 3
  1. #1
    New Lounger
    Join Date
    Aug 2002
    Location
    Cambridge, Massachusetts, USA
    Posts
    9
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Rounding When I Dont Want It (Access-2000)

    In short, I have a query that in most instances produces only whole numbers even though I do not want it to do so. Here is the equation:

    Test3: IIf([Zoning]<>"B",[MLZoneArea]2500,5559.333)

    A query using [MLZoneArea]2500 alone will produce fractional figures, but once I incorporate [MLZoneArea]2500 into an IIf function the calculation only yields results rounded to a whole number. In cases where [Zoning] does equal "B" the results is 5559.333 as expected but any instance where [Zoning] does not equal B produces only whole numbers..

    The value MLZoneArea is calculated in the same query from two other fields. One value resides in a table where the data type is Number and field size is Double. The other value comes from a series of queries but ultimately derives from a single table value where the data type is Number and field size is Double.

    Can anyone tell me what I am doing wrong? I'm out of ideas.

    Thanks for your help!

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Rounding When I Dont Want It (Access-2000)

    The operator provides integer division. If you want fractions, use /

  3. #3
    New Lounger
    Join Date
    Aug 2002
    Location
    Cambridge, Massachusetts, USA
    Posts
    9
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Rounding When I Dont Want It (Access-2000)

    Well that was simple. Thanks!!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •