Access query -- 1. 2. Use SELECT query to calculate grouped data
Access query -- 1. 2. Use SELECT query to calculate grouped data
2. Use SELECT query to calculate grouped data
Create a selection query, add "Fleet transportation query", and drag the "Driver, cargo category, and net weight" field to the design grid. Click "Total" in the toolbar.
, The total rows are added to the design grid, and the total number of drivers and cargo categories is set to "Group By" (keep unchanged ), set the total value of the net weight column to "Sum", which means to calculate the total value based on the driver and cargo Category field grouping. The query results are as follows:
Driver goods category transportation total Li Dafang waste stone 170.00 Li Dafang essence powder 1715.40 Li Dafang ore 13.50 Li Dafang other 310.00 Wang chic waste stone 18.50 Wang chic essence powder 922.30 Wang chic ore 15.90 Wang chic other 21.30 Zhang cute Waste Rock 310.00 cute powder sheets 1601.90 cute ore sheets 94.20 cute others 340.00 Zhao beautiful Waste Rock 790.00 Zhao beautiful fine powder 1537.40 Zhao beautiful ore 21.60 Zhao beautiful other 420.00