Re: SELECT query with multiple "WHERE" Clause

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



$query = mysql_query("SELECT * from gig WHERE gigName='$gig_name' or
gig_fdate='$sdate'");

You can not use more then one WHERE in your sql statement... And SQL accepts
OR and AND..  


--
Stephen Johnson c | eh
The Lone Coder

http://www.thelonecoder.com
continuing the struggle against bad code

http://www.fortheloveofgeeks.com
I¹m a geek and I¹m OK!
--




> From: Nasreen Laghari <nasreen_laghari@xxxxxxxxx>
> Date: Wed, 27 Feb 2008 15:44:23 -0800 (PST)
> To: <php-db@xxxxxxxxxxxxx>
> Subject:  SELECT query with multiple "WHERE" Clause
> 
> 
> 
> $query = mysql_query("SELECT * from gig WHERE gigName='$gig_name' ||
> gig_fdate='$sdate'");

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux