我在使用这个 Access SQL 时遇到了困难......我希望所有活动的 CustomerID 都出现,无论 OrderDate 是否匹配,我都无法弄清楚我做错了什么。
SELECT
tblCustomers_PullLists.CustomerID,
tblCustomers_PullLists.Title,
tblCustomers_PullLists.Active,
tblCustomers.FullName,
tblOrders.OrderDate,
tblCustomers.Notes
FROM
(
(
tblCustomers_PullLists
INNER JOIN
tblOrderDetails
ON tblCustomers_PullLists.Title = tblOrderDetails.Title
)
INNER JOIN
tblOrders
ON tblOrderDetails.OrderNumber = tblOrders.ID
)
LEFT JOIN
tblCustomers
ON tblCustomers_PullLists.CustomerID = tblCustomers.ID
WHERE (((tblCustomers_PullLists.Active)=Yes)
AND ((tblOrders.OrderDate)=[Please enter order date]))
ORDER BY tblCustomers_PullLists.CustomerID;
任何帮助将不胜感激!!