RE: [PHP-DB] query
| From: | Gary dot Every at ingramentertainment dot com | Date: | Tue, 04 Jun 2002 16:12:18 +0000 |
| Subject: | RE: [PHP-DB] query | ||
| Groups: | php.db | ||
| Request: | Send a blank email to php-db+get-19602@lists.php.net to get a copy of this message | ||
Instead of <> use !=
Gary Every
Sr. UNIX Administrator
Ingram Entertainment
(615) 287-4876
"Pay It Forward"
mailto:gary.every@ingramentertainment.com
http://accessingram.com
-----Original Message-----
From: Natividad Castro [mailto:ncastro@cots.com]
Sent: Tuesday, June 04, 2002 11:06 AM
To: php-db@lists.php.net
Subject: [PHP-DB] query
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
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php