query
| From: | Natividad Castro | Date: | Tue, 04 Jun 2002 16:05:44 +0000 |
| Subject: | query | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-19601@lists.php.net to get a copy of this message | ||
Hi to all,
can anyone please tell me what I'm doing wrong in this query?
This one doesn't work when I use <> operator
INSERT INTO record_status(rec_id) select 150bk.ID from 150bk
WHERE PHY_ST<>'IN' Or PHY_ST<>'OR' Or PHY_ST<>'PA'
Or PHY_ST<>'IA' Or
PHY_ST<>'MN' Or PHY_ST<>'CO' Or PHY_ST<>'ME' Or
PHY_ST<>'TN' Or
PHY_ST<>'GA';
but this one works with = operator
INSERT INTO record_status(rec_id) select 150bk.ID from 150bk
WHERE PHY_ST='IN' Or PHY_ST='OR' Or PHY_ST='PA' Or
PHY_ST='IA' Or
PHY_ST='MN' Or PHY_ST='CO' Or PHY_ST='ME' Or PHY_ST='TN' Or
PHY_ST='GA';
Thanks in advanced
Nato