Kamis, 22 Juni 2017

[MS_AccessPros] Sum of inventory by date question

 

We have a database that tracks inventory being used sort of like a rental database. the database is for events that users can order chairs, tables etc for the moving and event department to deliver. I need to get a query to show the sum of inventory for chairs for every date being delivered. I have a table such as below.

the main sql is below


SELECT Events.EventID, tblEventDetails.Quantity, Events.DeliveryDt, Events.EventEndDt, Events.EventStartDt, Events.EventEndDt, Events.PickupDt
FROM Events INNER JOIN tblEventDetails ON Events.EventID = tblEventDetails.EventID
WHERE (((tblEventDetails.ItemID)=23))
ORDER BY Events.EventID, Events.DeliveryDt;





Event Id 18624

Qty    14

DeliveryDt 6/29/2017

EventEndDt    8/1/2017


another record

Event id 19214

Qty    200

DeliveryDt    6/29/2017

EventEndDt    6/30/2017


so I am trying to break it down so that each date has a sum for the inventory type


how could I get a query (probably a crosstab) to show each date with the sum like below

6/29/2017 214

6/30/2017 214

7/1/2017 14

7/2/2014 14


etc


Thank you for any help.


Jim Wagner



__._,_.___

Posted by: luvmymelody@yahoo.com
Reply via web post Reply to sender Reply to group Start a New Topic Messages in this topic (1)

Have you tried the highest rated email app?
With 4.5 stars in iTunes, the Yahoo Mail app is the highest rated email app on the market. What are you waiting for? Now you can access all your inboxes (Gmail, Outlook, AOL and more) in one place. Never delete an email again with 1000GB of free cloud storage.


.

__,_._,___

Tidak ada komentar:

Posting Komentar