Re: Why won't this query work?

From: Date: Mon, 24 Mar 2008 17:50:25 +0000
Subject: Re: Why won't this query work?
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-272043@lists.php.net to get a copy of this message
Okay... so as happens to me more times then I care to admit... as soon as I sent it I simply added: .....WHERE customerBusiness='$business'..... and it works just fine... Sorry for the noise! On Mar 24, 2008, at 1:47 PM, Jason Pruim wrote:
Hi Everyone, Attempting to get this query: "SELECT customerName, loginName, email, adminLevel FROM current WHERE customerBusiness=$business ORDER BY adminLevel" to work. So far it doesn't like me... It pops up saying that "Unknown column 'Raoset' in 'where clause'" Here is what I get if I echo the query: SELECT customerName, customerBusiness, loginName, email, adminLevel FROM current WHERE customerBusiness='Raoset' $business is populated from a session variable and echos right... What I can't figure out is what in the world is wrong... If I type in the variable info, it works just fine. So why can't I pull it from a variable? -- Jason Pruim Raoset Inc. Technology Manager MQC Specialist 3251 132nd ave Holland, MI, 49424-9337 www.raoset.com japruim@raoset.com
-- Jason Pruim Raoset Inc. Technology Manager MQC Specialist 3251 132nd ave Holland, MI, 49424-9337 www.raoset.com japruim@raoset.com

« previous php.general (#272043) next »