where clauses with and
От | paul butler |
---|---|
Тема | where clauses with and |
Дата | |
Msg-id | T5dfefe9b20ac1785c30d4@pcow058m.blueyonder.co.uk обсуждение исходный текст |
Ответы |
Re: where clauses with and
|
Список | pgsql-novice |
Here's an odd one: I can't seem to make a where clause containing 'and' work db=# select orgname,usertype from users where usertype='Drug Addiction'; orgname | usertype ------------------------------------+---------------- Turning Point Scotland | Drug Addiction Govan Youth Access Project | Drug Addiction Community Learning West Team | Drug Addiction Possil Learning Centre | Drug Addiction Langside College (Glenwood Campus) | Drug Addiction Rehab Remanufacturing Services Ltd | Drug Addiction Greater Pollok Addiction Service | Drug Addiction db=# select orgname,usertype from users where usertype='Alcohol Addiction'; orgname | usertype ------------------------------------+------------------- Possil Learning Centre | Alcohol Addiction Greater Pollok Age Concern | Alcohol Addiction Rehab Remanufacturing Services Ltd | Alcohol Addiction Greater Pollok Addiction Service | Alcohol Addiction db=# select orgname from users where usertype='Alcohol Addiction' and usertype ='Drug Addiction'; orgname | usertype ---------+---------- (0 rows) I would expect orgnames: Greater Pollok Addiction Service, Rehab Remanufacturing Services Ltd to be returned. Any idea where I'm going wrong? Cheers Paul Butler
В списке pgsql-novice по дате отправления: