PC Review


Reply
Thread Tools Rate Thread

Re: Query to show items before a nominated Date

 
 
John W. Vinson
Guest
Posts: n/a
 
      16th Apr 2012
On Sun, 15 Apr 2012 07:41:09 GMT, David Ball <(E-Mail Removed)> wrote:

>Hi,
>
>I have a database table of Forecast Delivery Dates.
>I want to set up a Query to show items that have a forecast delivery date before a certain date. I want to be able to nominate that "certain date" on the fly.
>
>I have tried to set up a "Date" field where I can enter a date as a parameter, then have a calculated field to subtract the Forecast dates from the date entered.
>
>This returns an error. I think it is because the date returned by my new field doesn't seem to be in date format. I can't find any way to set this to date type.
>
>How can I make my new date field return results as dates?
>
>Is there a better, more direct way to do this?
>
>I tried:
>
> InvalidDates: [ForecastDate]<[Enter Date]
>
>where "ForecastDate" is the field for my delivery date forecasts and "Enter Date" generates a parameter box where I enter a date. This didn't work either (maybe the date I'm entering into the parameter box is not showing as a date?).
>
>Thanks very much for any help with this.
>
>Dave
>
>
>


You can use a Form with a textbox, frmCrit and txtDate let's say, and use a
Query with a criterion

< [Forms]![frmCrit]![txtDate]

It's often helpful to define this in the query's Parameters collection:
rightclick the background of the tables window in query design; select
Parameters; copy and paste [Forms]![frmCrit]![txtDate] in the left column of
the grid and specify Date/Time in the right. You certainly should not be
creating a new table field to do this.
--

John W. Vinson [MVP]
Microsoft's replacements for these newsgroups:
http://social.msdn.microsoft.com/For...-US/accessdev/
http://social.answers.microsoft.com/.../en-US/addbuz/
and see also http://www.utteraccess.com
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Nominated Date+Nominated number of workdays =?Utf-8?B?Q2hyaXNS?= Microsoft Access 4 27th Jul 2006 12:09 AM
Display report for nominated client mandyric@bigpond.net.au Microsoft Access Queries 0 21st Mar 2006 08:13 AM
Nominated range not recognised in User Defined Funtion =?Utf-8?B?TWF0dCBSb2JlcnRz?= Microsoft Excel Programming 1 25th Jan 2006 01:18 PM
ANN: Picture ProgressBar Nominated "Gold Download" Saulo I. Regis Microsoft C# .NET 0 12th Aug 2004 04:13 PM
Saving Windows Updates To A Nominated Folder. Mark Hickman Windows XP Performance 1 18th Jan 2004 07:49 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 02:01 PM.