
November 18th, 2003, 12:25 PM
|
|
Junior Member
|
|
Join Date: Nov 2003
Location: Hawaii
Posts: 2
Time spent in forums: < 1 sec
Reputation Power: 0
|
|
query help
Hello,
I'm not sure if this can be done using a sql, but I'm trying to select the userids of the rows that doesn't have a certain value, in this example, I want to select the userid who didn't order any pencils, so if they had ordered something else and some pencils, I do not want these rows.
so in this example, I would like to select only userid 2 (and only one row is desired to be returned); is this possible with sql?
thank you in advance!
userid item price
-------- ----------- ------
1 pen .25
1 pencil .15
1 eraser .50
2 pen .25
2 eraser .50
3 pen .25
3 pencil .15
3 eraser .50
|