|
[PHP]SELECT DISTINCT [SV-5.NameA]
FROM ([SV-5] LEFT JOIN SFtoFD ON [SV-5].NAMEA = SFtoFD.NAMEB) LEFT JOIN SFtoSV4 ON [SV-5].NAMEA = SFtoSV4.NAMEB
WHERE SFtoSV4.NAMEB IS NULL AND SFtoFD.NAMEB IS NULL;[/PHP]
This returns 9 records, which is the right amount. Now when I use
[PHP]SELECT COUNT(DISTINCT [SV-5.NameA])[/PHP]
I get an error message. What's my problem. Without the DISTINCT I get a count of 48 records which is not right.
|