RE: [PHP] mysql error, dont see why.. please help

From: Date: Tue, 22 May 2001 21:05:32 +0000
Subject: RE: [PHP] mysql error, dont see why.. please help
Groups: php.general 
Request: Send a blank email to php-general+get-53934@lists.php.net to get a copy of this message
The SET clause has to come before WHERE clause - Russ --- Toolshed Computer Productions - Professional PHP Hosting Hosting - Dedicated Servers - Design - Programming http://www.toolshed51.com -----Original Message----- From: Tyler Longren [mailto:tyler.longren@midiowa.net] Sent: Tuesday, May 22, 2001 2:04 PM To: PeterOblivion@aol.com Cc: php-general@lists.php.net Subject: Re: [PHP] mysql error, dont see why.. please help Shouldn't it be: mysql_query("UPDATE user_polls SET url = '$file_name' WHERE uid = '$UserName' AND type = '$type") or die (mysql_error()); Maybe I'm wrong. -- Tyler Longren tyler.longren@midiowa.net Currently Unemployed www.noworkfortyler.com On Tue, 22 May 2001 17:00:35 EDT PeterOblivion@aol.com wrote: > Here is the command. > > mysql_query("UPDATE user_polls WHERE uid = '$UserName' AND type = '$type' SET > url = '$file_name'") or die(mysql_error()); > > Output > You have an error in your SQL syntax near 'WHERE uid = 'Oblivion' AND type = > 'music' SET url = 'test'' at line 1 > > This is SOOO weird. > PLEASE HELP > > - Peter > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net > -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net For additional commands, e-mail: php-general-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.general (#53934) next »