Try this ---
SELECT PODet_wCustInfo_qry.ContactID, PODet_wCustInfo_qry.ContRactID,
PODet_wCustInfo_qry.POID, PODet_ItemInfo_qry.ItemPrice,
PODet_ItemInfo_qry.Quantity, PODet_ItemInfo_qry.Amount,
PODet_wCustInfo_qry.CustomerDate, Year(PODet_wCustInfo_qry.CustomerDate) AS
Expr1, PODet_wCustInfo_qry.DateComplete, ContRact_wPOID_qry.Extras,
ContRact_wPOID_qry.[Cost of Building]
FROM PODet_ItemInfo_qry INNER JOIN (ContRact_wPOID_qry INNER JOIN
PODet_wCustInfo_qry ON ContRact_wPOID_qry.POID = PODet_wCustInfo_qry.POID)ON
PODet_ItemInfo_qry.POID = PODet_wCustInfo_qry.POID
WHERE [DateComplete] Between #1/1/2006# And #1/1/2007#;
--
KARL DEWEY
Build a little - Test a little
Ronnie said:
SELECT PODet_wCustInfo_qry.ContactID, PODet_wCustInfo_qry.ContRactID,
PODet_wCustInfo_qry.POID, PODet_ItemInfo_qry.ItemPrice,
PODet_ItemInfo_qry.Quantity, PODet_ItemInfo_qry.Amount,
PODet_wCustInfo_qry.CustomerDate, Year(PODet_wCustInfo_qry.CustomerDate) AS
Expr1, PODet_wCustInfo_qry.DateComplete, ContRact_wPOID_qry.Extras,
ContRact_wPOID_qry.[Cost of Building], [DateComplete] Between #1/1/2006# And
#1/1/2007# AS Expr2
FROM PODet_ItemInfo_qry INNER JOIN (ContRact_wPOID_qry INNER JOIN
PODet_wCustInfo_qry ON ContRact_wPOID_qry.POID = PODet_wCustInfo_qry.POID) ON
PODet_ItemInfo_qry.POID = PODet_wCustInfo_qry.POID;
--
Ronnie
KARL DEWEY said:
Post your SQL.
--
KARL DEWEY
Build a little - Test a little
:
I tried this, but it did not pull the dates between the dates I requested.
It still pulls every record. I also need to be able to enter the dates from
and to.
--
Ronnie
:
Hi Ronnie,
An example of the SQL would be:
SELECT *
FROM [TABLE NAME]
WHERE DateComplete Between #1/1/2006# And #1/1/2007#
;
I am trying to create an expression to select items from a date field falling
from a certain date to a certain date. I am obviously missing something in
my expression. The field name is DateComplete. How can I set up this
expression to pull date from a certain date to a certain date?