Connecting Tech Pros Worldwide Help | Site Map

No Of Days

 
LinkBack Thread Tools Search this Thread
  #1  
Old November 13th, 2005, 06:07 AM
KEVIN97810
Guest
 
Posts: n/a
Default No Of Days

hello to all,
I have a date field in my table (last, first, address,
contact, Date) and i want to write a select statement example
based on the date field. Give me 30 days, 30 to 90, 90 to 100 from that date
field
when i clicked the option group.

Select of of the following

[ ] 30 days
[ ] 30 to 90 days
[ ] 90 to 100 days

than i will use this query to run my reports.

thanks




  #2  
Old November 13th, 2005, 06:07 AM
fredg
Guest
 
Posts: n/a
Default Re: No Of Days

On 10 Jan 2005 02:46:52 GMT, KEVIN97810 wrote:
[color=blue]
> hello to all,
> I have a date field in my table (last, first, address,
> contact, Date) and i want to write a select statement example
> based on the date field. Give me 30 days, 30 to 90, 90 to 100 from that date
> field
> when i clicked the option group.
>
> Select of of the following
>
> [ ] 30 days
> [ ] 30 to 90 days
> [ ] 90 to 100 days
>
> than i will use this query to run my reports.
>
> thanks[/color]

As criteria on the Date Field in your query use one of the below.
For 30 days:
Between [DateField] and DateAdd("d",30,[DateField])
For 30 to 90 days:
Between DateAdd("d",30,[DateField]) and DateAdd("d",90,[DateField])
For 90 to 100 days:
Between DateAdd("d",90,[DateField]) and DateAdd("d",100,[DateField])
--
Fred
Please only reply to this newsgroup.
I do not reply to personal email.
 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search

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

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Popular Articles

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over 220,840 network members.