Calculation for an Access Report

T

Thiazi

I have a unique calculation I need to produce and have the results
appear on an Access Report. I need to take the value of a value in a
column and essentially do the following:

if the value in the column is 15 - 20, assign a point value of 1
if the value in the column is 21 - 25, assign a point value of 2
if the value of the column is 26 - 30, assign a point value of 3

The column value will appear on the Access Report regardless, and I
need the point value to appear as well. How would I perform this
calculation in Access? I know in Excel I can perform it with the
LOOKUP command.
 
W

Wayne-I-M

Hi

Create an unbound box in the details of the report and use something like

= IIf([Value] Between 15 And 20,1,IIf([Value] Between 21 And
25,2,IIf([Value] Between 26 And 30,3)))

Notes = Value in the about source is the name of the field you are refering
to. Change this to what it is in your report
I take it that the value will always be somewhere between 15 and 30. If not
your will need to alter the above and add a value after the last 3 -
like this 3,Something)))
 
T

Thiazi

I should have posted with this - I accomplish this in excel with
=LOOKUP(cell name,{15,21,26},{1,2,3})

What is the access equivalent the =LOOKUP command in Excel to do this?
 
T

Thiazi

I should have posted with this - I accomplish this in excel with
=LOOKUP(cell name,{15,21,26},{1,2,3})

What is the access equivalent the =LOOKUP command in Excel to do this?






- Show quoted text -

Is this not possible? :(
 
Top