Solved

Query not pulling correct date

Posted on 2008-06-17
3
218 Views
Last Modified: 2012-06-27
The following query is pulling all dates from the table instead of the parameters enter by the user.  Any thoughts?

SELECT [Raw Plate Table].Filler, [Raw Plate Table].SPC, [Raw Plate Table].Coli, [Raw Plate Table].[Production Date]
FROM [Raw Plate Table]
ORDER BY ([Raw Plate Table].[Production Date] Between [Enter First Date] And [Enter Second Date]);

0
Comment
Question by:kellyputty
3 Comments
 
LVL 38

Expert Comment

by:Jim P.
ID: 21805029
Is the [Enter First Date] less than  [Enter Second Date]?
0
 
LVL 1

Accepted Solution

by:
jenleej earned 500 total points
ID: 21805059
Wouldn't you want a 'WHERE' clause?  WHERE [Raw Plate Table].[Production Date] > [Enter First Date] and [Raw Plate Table].[Production Date] < [Enter Second Date]
0
 

Author Closing Comment

by:kellyputty
ID: 31468045
Thanks.
0

Featured Post

Backup Your Microsoft Windows Server®

Backup all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes how to use the timestamp of existing data in a database to allow Tableau to calculate the prior work day instead of relying on case statements or if statements to calculate the days of the week.
A simple tool to export all objects of two Access files as text and compare it with Meld, a free diff tool.
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

910 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

22 Experts available now in Live!

Get 1:1 Help Now