Calculating number of days between multiple dat2

V

Vannak Uong

How do I write codes to calculate the number of days for the following
time interval for each persno:

7/1/01 to 6/30/02
7/1/02 to 6/30/03
7/1/03 to 6/30/04
7/1/04 to 6/30/05
7/1/05 to 6/30/06
7/1/06 to 6/30/07
7/1/07 to 6/30/08
7/1/08 to 6/30/09
7/1/08 to 6/30/09

Here' sample data from my table with all six fields, Persno,PS group,
Lv, Annual salary,Start date.



Persno PS group Lv Annual salary Start date
11454 U75 1 " 71,510.40 " 11/01/04
11454 U75 2 " 76,398.40 " 07/01/05
11454 U75 3 " 81,286.40 " 06/26/06
11518 B466 1 " 44,718.70 " 10/04/04
11518 B466 2 " 46,865.94 " 04/01/05
11518 B466 3 " 49,126.69 " 03/27/06
11518 B466 4 " 51,524.72 " 03/22/07
11518 B466 5 " 54,060.03 " 03/16/08
11527 B420 1 " 35,994.40 " 11/08/04
11527 B420 2 " 37,730.16 " 05/01/05
11527 B420 3 " 39,534.35 " 04/26/06
11527 B420 4 " 41,453.15 " 04/21/07
11527 B420 5 " 43,462.64 " 04/15/08


Thank you,

Van
 
G

Guest

use the DateDiff function, somrthing like the below aircode

DateDiff("d", [FirstDate], [LastDate])

-Rosco
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top