Re: Subject: mysql field comparison to multiple variables

From: Date: Sun, 26 Oct 2003 12:42:01 +0000
Subject: Re: Subject: mysql field comparison to multiple variables
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-31300@lists.php.net to get a copy of this message
At 11:24 26/10/2003 +0000, you wrote:
Message-ID: <3F99D5D2.3030807@wkla.com> Date: Fri, 24 Oct 2003 21:45:54 -0400 From: Mike Baerwolf <mike@wkla.com> MIME-Version: 1.0 To: php-db@lists.php.net Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Subject: mysql field comparison to multiple variables Hello, I trying to put together a sql statement that will pull records based on a date field. I can't figure out how to compare the date field to multiple php variables. Something like this, WHERE date_field != $date_1 OR $date_2 OR $date_3 etc. etc.
WHERE date_field NOT IN ($date_1,$date_2,$date3)
Thanks for the help. Mike


« previous php.db (#31300) next »