Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

If Stataments in Queries 1

Status
Not open for further replies.

Wrecker

Technical User
Aug 29, 2001
126
US
Can If statments be written in the criteria setion of a Query? I need to change the amount a number is multiplied by, depending on the text in a field. I know how to do it in a module for a form, but i'm not sure how to do it in a Query.

Thanks in Advance
Wrecker
 
Hi Wrecker

You just need to use iif in a query

e.g.

iif([FieldA]="A",OldValue*Multiplier1,OldValue*Multiplier2)

Regards

Tom
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top