B Beth McLaren Jun 30, 2009 #1 What formula within a query do you use to count dates, i.e. 5/1/09 through 6/4/09 for example....????
What formula within a query do you use to count dates, i.e. 5/1/09 through 6/4/09 for example....????
B Beetle Jun 30, 2009 #2 DateDiff("d", #5/1/2009#, #6/4/2009#) will return the number of days (I'm assuming you want days). Assuming your data is actually in table fields; DateDiff("d", [Field1], [Field2]) If you want to include the second field in the returned result you'll have to add one; DateDiff("d", [Field1], [Field2]) + 1
DateDiff("d", #5/1/2009#, #6/4/2009#) will return the number of days (I'm assuming you want days). Assuming your data is actually in table fields; DateDiff("d", [Field1], [Field2]) If you want to include the second field in the returned result you'll have to add one; DateDiff("d", [Field1], [Field2]) + 1