R
Richard Horne
I have the following query:
SELECT Deliveries.OrderNumber, Orders.OrderNumber,
Delivery_Details.DeliveryNoteID, Orders.[Customer Name], Orders.[Order Date],
Order_Details.[Item Number], Order_Details.[Item Type],
Order_Details.Description, Order_Details.Type_Colour_Size,
Order_Details.Quantity, Order_Details.Denomination,
Delivery_Details.ItemNumber, Delivery_Details.QtyDelivered, Deliveries.Date,
Deliveries.Despatch, Products.Product, Denominations.Denom
FROM Company_Details INNER JOIN ((Denominations INNER JOIN ((Orders INNER
JOIN (Delivery_Details INNER JOIN Order_Details ON
Delivery_Details.ItemNumber = Order_Details.[Item Number]) ON
Orders.OrderNumber = Order_Details.OrderNumber) INNER JOIN Deliveries ON
(Delivery_Details.DeliveryNoteID = Deliveries.DeliveryNoteID) AND
(Orders.OrderNumber = Deliveries.OrderNumber)) ON Denominations.denomid =
Order_Details.Denomination) INNER JOIN Products ON Order_Details.[Item Type]
= Products.Id) ON Company_Details.ID = Orders.[Customer Name]
WHERE (((Deliveries.OrderNumber)=[Orders].[OrderNumber])) ORDER BY
Orders.OrderNumber, Order_Details.[Item Number];
Apologies for the length and 'complicatedness' of it. Can anyone tell me how
to display this query such that the field Delivery_Details.QtyDelivered is
totalled up and displayed instead of each record and the different Qtys
Delivered.
SELECT Deliveries.OrderNumber, Orders.OrderNumber,
Delivery_Details.DeliveryNoteID, Orders.[Customer Name], Orders.[Order Date],
Order_Details.[Item Number], Order_Details.[Item Type],
Order_Details.Description, Order_Details.Type_Colour_Size,
Order_Details.Quantity, Order_Details.Denomination,
Delivery_Details.ItemNumber, Delivery_Details.QtyDelivered, Deliveries.Date,
Deliveries.Despatch, Products.Product, Denominations.Denom
FROM Company_Details INNER JOIN ((Denominations INNER JOIN ((Orders INNER
JOIN (Delivery_Details INNER JOIN Order_Details ON
Delivery_Details.ItemNumber = Order_Details.[Item Number]) ON
Orders.OrderNumber = Order_Details.OrderNumber) INNER JOIN Deliveries ON
(Delivery_Details.DeliveryNoteID = Deliveries.DeliveryNoteID) AND
(Orders.OrderNumber = Deliveries.OrderNumber)) ON Denominations.denomid =
Order_Details.Denomination) INNER JOIN Products ON Order_Details.[Item Type]
= Products.Id) ON Company_Details.ID = Orders.[Customer Name]
WHERE (((Deliveries.OrderNumber)=[Orders].[OrderNumber])) ORDER BY
Orders.OrderNumber, Order_Details.[Item Number];
Apologies for the length and 'complicatedness' of it. Can anyone tell me how
to display this query such that the field Delivery_Details.QtyDelivered is
totalled up and displayed instead of each record and the different Qtys
Delivered.