P
Pat B
I’m trying to write an IIf statement in an Access query that I’m having
problems with. I want to calculate the number of days between a Date
Received and Date Left. If the Date Left is null, then I want to calculate
the number of days between Date Received and date query is run. To calculate
the number of days where both fields have a value, the following works:
Total Days
ateDiff(“dâ€,[Date Recd],[Date Left].
I tried the following to incorporate instances where Date Left is blank,but
it says it contains invalid syntax.
Total Days:IIf(isNull[DateLeft],DateDiff(“dâ€,[Date
Recd,[Date()],DateDiff(“dâ€,[Date Recd],[Date Left])))
Help will really be appreciated.
problems with. I want to calculate the number of days between a Date
Received and Date Left. If the Date Left is null, then I want to calculate
the number of days between Date Received and date query is run. To calculate
the number of days where both fields have a value, the following works:
Total Days
I tried the following to incorporate instances where Date Left is blank,but
it says it contains invalid syntax.
Total Days:IIf(isNull[DateLeft],DateDiff(“dâ€,[Date
Recd,[Date()],DateDiff(“dâ€,[Date Recd],[Date Left])))
Help will really be appreciated.