Date Calculation

  • Thread starter Thread starter zyus
  • Start date Start date
Z

zyus

I have aprdt (date field) and want to add number from arrmth (number field)
to get new date..

For ex

Aprdt arrmth newdate
31/07/09 1 31/08/09
31/07/09 2 30/09/09

How to do it in query....TQ
 
zyus said:
I have aprdt (date field) and want to add number from arrmth (number field)
to get new date..

For ex

Aprdt arrmth newdate
31/07/09 1 31/08/09
31/07/09 2 30/09/09

How to do it in query....TQ

Actually what i really want is the aprdt minus arrmth and the new result
will be
 
Actually what i really want is the aprdt minus arrmth and the new result
will be

i would suggest you look up the DateAdd function in VBA help.

To add the arrmth value to a date in a query:
NewDate:DateAdd("m",[arrmth],[Aprdt])

To subtract the arrmth value from a date:
NewDate:DateAdd("m",-[arrmth],[Aprdt])
 
Back
Top