Conditional statement within a query?

  • Thread starter Thread starter Jeff
  • Start date Start date
J

Jeff

Can I use a conditional statement within a query field. E.g.:

If RecordDate is > DeadlineDate then
show interest calc in field
else
show different interest calc in field
end if
 
Jeff said:
Can I use a conditional statement within a query field. E.g.:

If RecordDate is > DeadlineDate then
show interest calc in field
else
show different interest calc in field
end if

To do this in a query you will need to use the Iif function. Look it up in
Help.
 
Can I use a conditional statement within a query field. E.g.:

If RecordDate is > DeadlineDate then
show interest calc in field
else
show different interest calc in field
end if

Add a new column to the query grid.

IntCalc:IIf([RecordDate]>[DeadlineDate],interestA,interestB)
 
Back
Top