Hi,
Currently I use perl / MySQL for web reporting for our Parts and Suppliers database ... I've been having difficulty implementing the following using an SQL SELECT statement only ... instead resorting to perl to refine the SELECT results ...
Parts - Supplier Database as follows (relevent tables and attributes shown only)
Supplier
--------
SuppNo
SuppName
SuppAddress
SuppParts
---------
SuppNo
PartNo
Qty
Now, I wish to create a web report which displays a suppliers details who do not supply a particular part ...
e.g.
SELECT SuppNo, SuppName, SuppAdress FROM Supplier, SuppParts
WHERE SuppParts.pNo != 'Part1' AND Supplier.SuppNo = SuppParts.SuppNo;
now, this statement is OK for instances where 'Part1' is not supplied by a particular Supplier however it does not produce the result I'm ideally looking for.
Can anyone provide any hints or tips on how I can proceed?
is it possible on SQL?
Thanks,
SP
Currently I use perl / MySQL for web reporting for our Parts and Suppliers database ... I've been having difficulty implementing the following using an SQL SELECT statement only ... instead resorting to perl to refine the SELECT results ...
Parts - Supplier Database as follows (relevent tables and attributes shown only)
Supplier
--------
SuppNo
SuppName
SuppAddress
SuppParts
---------
SuppNo
PartNo
Qty
Now, I wish to create a web report which displays a suppliers details who do not supply a particular part ...
e.g.
SELECT SuppNo, SuppName, SuppAdress FROM Supplier, SuppParts
WHERE SuppParts.pNo != 'Part1' AND Supplier.SuppNo = SuppParts.SuppNo;
now, this statement is OK for instances where 'Part1' is not supplied by a particular Supplier however it does not produce the result I'm ideally looking for.
Can anyone provide any hints or tips on how I can proceed?
is it possible on SQL?
Thanks,
SP