G
Guest
I am working in Access 97. I have the following query:
SELECT tblPromo.UPCFip13, tblProd.ProdDesc, tblPromo.PromoNo, tblPromo.UOM,
tblPromo.StartDate, UCase(Mid([StartWkdy],1,2)) AS [START DAY],
tblPromo.EndDate, UCase(Mid([EndWkdy],1,2)) AS [END DAY], tblPromo.Price,
tblPromo.Factor, tblPromo.Type
FROM tblPromo INNER JOIN tblProd ON tblPromo.UPCFip13 = tblProd.UPCFip13
WHERE (((tblPromo.PromoNo)=(SELECT DISTINCT tblPromo.PromoNo FROM tblPromo))
AND ((tblPromo.StartDate)>=Date()))
ORDER BY tblPromo.StartDate;
I am having problems with
SELECT DISTINCT tblPromo.PromoNo FROM tblPromo
It says it will only return one record when I know there are 428 records
that should be returned. The bottom line is that I only want one Promo No
returned per line. Note: If I remove this criteria the query runs just fine
but returns me multiple Promo nos.
The unique value property doesn't work because there might be a variety of
UPC's (Item nos.) Any help would be appreciated.
SELECT tblPromo.UPCFip13, tblProd.ProdDesc, tblPromo.PromoNo, tblPromo.UOM,
tblPromo.StartDate, UCase(Mid([StartWkdy],1,2)) AS [START DAY],
tblPromo.EndDate, UCase(Mid([EndWkdy],1,2)) AS [END DAY], tblPromo.Price,
tblPromo.Factor, tblPromo.Type
FROM tblPromo INNER JOIN tblProd ON tblPromo.UPCFip13 = tblProd.UPCFip13
WHERE (((tblPromo.PromoNo)=(SELECT DISTINCT tblPromo.PromoNo FROM tblPromo))
AND ((tblPromo.StartDate)>=Date()))
ORDER BY tblPromo.StartDate;
I am having problems with
SELECT DISTINCT tblPromo.PromoNo FROM tblPromo
It says it will only return one record when I know there are 428 records
that should be returned. The bottom line is that I only want one Promo No
returned per line. Note: If I remove this criteria the query runs just fine
but returns me multiple Promo nos.
The unique value property doesn't work because there might be a variety of
UPC's (Item nos.) Any help would be appreciated.