Query is Retrieving too few Record

E

Elizabeth

My query is not retrieving all of the records that should be included in the
dataset. I've included the SQL for your review. Please help.

SELECT qryReportData.Order, qryReportData.[Created on], qryReportData.[Ship
To List name], qryReportData.[Ship to City], qryReportData.[Ship to State],
qryReportData.[Sales doc], qryReportData.[Purchase Order],
qryReportData.[Caller Name], qryReportData.[Clarify Number],
qryReportData.[Product No], qryReportData.[Product Serial],
qryReportData.[Part No#], qryReportData.[Part Description],
qryReportData.Quantity, qryReportData.[Cust Cost], qryRepairCosts.RepairCost,
qryTravelCosts.TravelCost
FROM (qryReportData LEFT JOIN qryRepairCosts ON qryReportData.Order =
qryRepairCosts.Order) LEFT JOIN qryTravelCosts ON qryReportData.Order =
qryTravelCosts.Order
WHERE (((qryReportData.[Cust Cost])<>0) AND ((qryRepairCosts.RepairCost) Is
Null Or (qryRepairCosts.RepairCost)<>0) AND ((qryTravelCosts.TravelCost) Is
Null Or (qryTravelCosts.TravelCost)<>0));


Thx
 
M

Michel Walsh

Hi,


You have the test on NULL right. What are the kind of records that should be
returned and that are not? I mean, if you remove the whole WHERE clause, are
they present?



Hoping it may help,
Vanderghast, Access MVP
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top