dbTalk Databases Forums  

dates

comp.database.ms-access comp.database.ms-access


Discuss dates in the comp.database.ms-access forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
 
Posts: n/a

Default dates - 05-11-2004 , 05:11 PM






hi everyone!
does anyone know how to filter a recordset for a specific date.
for example. i keep some dates in an access database of cpr training. i am
making a repeating region listing the people whose cpr license will expire
in 30 days. well how do you construct that kind of sql sentence
SELECT*
FROM table
WHERE cprduedate = <<<<<<<what>>>>>>>
i'm completely lost! i keep dates in form mm/dd/yyyy and am using asp.
thanks a bunch in advance



Reply With Quote
  #2  
Old   
Koyan
 
Posts: n/a

Default Re: dates - 05-12-2004 , 03:04 AM






jjrmy1 (AT) earthlink (DOT) net wrote:

Quote:
hi everyone!
does anyone know how to filter a recordset for a specific date.
for example. i keep some dates in an access database of cpr training. i am
making a repeating region listing the people whose cpr license will expire
in 30 days. well how do you construct that kind of sql sentence
SELECT*
FROM table
WHERE cprduedate = <<<<<<<what
i'm completely lost! i keep dates in form mm/dd/yyyy and am using asp.
thanks a bunch in advance
SELECT *
FROM table
WHERE ((Table.cprduedate)<=DateAdd("d",30,Date()));

This will give you all the people who expire in less than 30 days from
today.
SELECT *
FROM table
WHERE ((Table.cprduedate)=DateAdd("d",30,Date()));

This will give the people who expire exactly in 30 days from today.

Be well


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.