Link to home
Start Free TrialLog in
Avatar of gigifarrow
gigifarrow

asked on

Using Multiple criteria for iif Statemants

This criteria is based on the production number so far if it is >=73 or if it is <=4 it uses the first code but all else uses  the second code. The problem I have is that I have over 300 production number that need the first code. but in the 300 some do not so Im having to go aaround and pick and choose numbers.

How do I put like for example 300-400 as a criteria and then drop down to 200-250 with out having to name each production number individually? This is what Im tring to do.

IIf([Production]>=73 Or [Production]<=4 or [Production]=300-322 or [Production]= 400-422
and on with out having to name each number invidually instead of sayin 400 , 401, 402 etc.

This code works fine but i need to add more criteria

IIf([Production]>=73 Or [Production]<=4,

(Abs(([F]![Induction]*4+[F]![Defuel]*1+[F]![TurretPull]*3+[F]![FuelCellRemoved]*5+[F]![BFCSProvision]*3+[F]![Err]*10+[F]![TASS]*16+[F]![BASSDProvision]*8+[F]![BASSDInstalled]*14+[F]![BFCSInstalled]*10+[F]![TurretInstalled]*4+[F]![E1Ground]*1+[F]![DriverSeatSpacer]*1+[F]![GunnersSeatStop]*1+[F]![AFESSwitchGuard]*1+[F]![ReliefHoleExtinguisher]*1+[F]![25mmHotBox]*2+[F]![ErrHandleMod]*0+[F]![FuelShutoffSleeve]*1+[F]![FinalQAQC]*8+[F]![Outduction]*6)/100)*100),

(Abs(([F]![Induction]*5+[F]![Defuel]*1+[F]![TurretPull]*10+[F]![FuelCellRemoved]*10+[F]![BFCSProvision]*5+[F]![Err]*10+[F]![TASS]*10+[F]![BASSDProvision]*0+[F]![BASSDInstalled]*0+[F]![BFCSInstalled]*10+[F]![TurretInstalled]*10+[F]![E1Ground]*1+[F]![DriverSeatSpacer]*0+[F]![GunnersSeatStop]*1+[F]![AFESSwitchGuard]*1+[F]![ReliefHoleExtinguisher]*1+[F ]![25mmHotBox]*2+[F]![ErrHandleMod]*0+[F]![FuelShutoffSleeve]*1+[F]![FinalQAQC]*12+[F]![Outduction]*10)/100)*100)) & "%" AS Percentages
FROM tblYakimaFullup


Should I go another route?
SOLUTION
Avatar of Andy Marshall
Andy Marshall
Flag of United Kingdom of Great Britain and Northern Ireland image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Avatar of IrogSinta
IrogSinta
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
ASKER CERTIFIED SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial