lwarren1968
Registered User.
- Local time
- Today, 01:12
- Joined
- Jan 18, 2013
- Messages
- 77
I have a table (see below) that has redundant [UPC], however the [Available Qty] is different. What I need is a query that can list [UPC] without duplicates, which I was able to do using DISTINCT. But, I also need my query to return a grand total FILED for [Available Qty]. Any help with the calculation portion would be appreciated.
SELECT DISTINCT B2BinventoryGDL_TBL.UPC
FROM B2BinventoryGDL_TBL;
B2BinventoryGDL_TBL
SELECT DISTINCT B2BinventoryGDL_TBL.UPC
FROM B2BinventoryGDL_TBL;
B2BinventoryGDL_TBL
SKU | UPC | Stock Type | Product Style | Description | Description 2 | Warehouse | Available Qty | Next Arrival Date |
---|---|---|---|---|---|---|---|---|
A-SHIP1OZ | 022255371476 | Closeout | SHIP-0 GREASE 1OZ TUB | (RD 8675/1 OZ TUB) | IRV | 100 | ||
ABEANIECAMO | 022255470780 | Closeout | SHM BEANIE | SHM REVERSE BEANIE OSFM CAMO | NCH | 100 | ||
ABEANIENV | 022255470797 | Closeout | SHM BEANIE | SHM REVERSE BEANIE OSFM NVY | NCH | 100 | ||
AHATBLKOUTBK | 022255073912 | SHM BLACKOUT CAP | SHM BLACKOUT CAP OSFM BLK | COTTON/POLYESTER | IRV | 65 | ||
AHATBLKOUTBK | 022255073912 | SHM BLACKOUT CAP | SHM BLACKOUT CAP OSFM BLK | COTTON/POLYESTER | NCH | 100 | ||
AHATCOMBBK | 022255470803 | SHM HONEYCOMB | SHM HNYCMB MSH CAP OSFM BLK | IRV | 13 | |||
AHATCOMBBK | 022255470803 | SHM HONEYCOMB | SHM HNYCMB MSH CAP OSFM BLK | NCH | 10 | 2020-06-10 | ||
AHATCOMBGY | 022255470827 | SHM HONEYCOMB | SHM HNYCMB MSH CAP OSFM GRY | IRV | 71 | |||
AHATCOMBGY | 022255470827 | SHM HONEYCOMB | SHM HNYCMB MSH CAP OSFM GRY | NCH | 100 |