P
perryclisbee via AccessMonster.com
I did a query where I want to add on a certain amount of months to a date
depending on the contents of another field. Here is the statement I used:
SwitchDate: IIf([Active_SPA_summary_02d]![MODALITY]="*PD*",DateAdd("m",30,
[Active_SPA_summary_02d]![MaxOfFIRST_DIALYSIS]),DateAdd("m",33,
[Active_SPA_summary_02d]![MaxOfFIRST_DIALYSIS]))
Does this look right? I want to add 30 months to the original date
[MaxOfFIRST-DIALYSIS] if the MODALITY field has anything with the letters PD
in it. If it doesn't, I want to add 33 months to the original date. Will
the "*PD*" structure work accurately?
Thanks,
Perry
depending on the contents of another field. Here is the statement I used:
SwitchDate: IIf([Active_SPA_summary_02d]![MODALITY]="*PD*",DateAdd("m",30,
[Active_SPA_summary_02d]![MaxOfFIRST_DIALYSIS]),DateAdd("m",33,
[Active_SPA_summary_02d]![MaxOfFIRST_DIALYSIS]))
Does this look right? I want to add 30 months to the original date
[MaxOfFIRST-DIALYSIS] if the MODALITY field has anything with the letters PD
in it. If it doesn't, I want to add 33 months to the original date. Will
the "*PD*" structure work accurately?
Thanks,
Perry