J
Joanne
Hello,
In a query I am trying to enter the number of days a person has taken for a
particular vacation request, and I need to somehow determine 1/2 days, so if
the begin date and end date of the vacation are the same, I am entering .5.
If an employee wants a full day, they will have to enter the end data as the
next day. If the "type of day" is "Personal", "Jury Duty", or "Carryover", I
want Access to enter a "0". I set up a double Iif but if I try to add a
comma and a "0" it tells me I have too many arguments. So I'm not sure how
to proceed. Thank you very much for your help.
______________________________________
TotalVacation: IIf([Type Of Day] In ("Personal","Jury Duty","Carryover") And
[OLP Begin Date]=[OLP End Date],.5,IIf([Type Of Day] In ("Personal","Jury
Duty","Carryover") And [OLP Begin Date]<>[OLP End Date],DateDiff("d",[OLP
Begin Date],[OLP End Date]),0)
In a query I am trying to enter the number of days a person has taken for a
particular vacation request, and I need to somehow determine 1/2 days, so if
the begin date and end date of the vacation are the same, I am entering .5.
If an employee wants a full day, they will have to enter the end data as the
next day. If the "type of day" is "Personal", "Jury Duty", or "Carryover", I
want Access to enter a "0". I set up a double Iif but if I try to add a
comma and a "0" it tells me I have too many arguments. So I'm not sure how
to proceed. Thank you very much for your help.
______________________________________
TotalVacation: IIf([Type Of Day] In ("Personal","Jury Duty","Carryover") And
[OLP Begin Date]=[OLP End Date],.5,IIf([Type Of Day] In ("Personal","Jury
Duty","Carryover") And [OLP Begin Date]<>[OLP End Date],DateDiff("d",[OLP
Begin Date],[OLP End Date]),0)