Re: [PHP-DB] SQL update help

2002-09-21 Thread Ignatius Reilly
, September 21, 2002 2:07 AM Subject: Re: [PHP-DB] SQL update help Jeffrey is right, but here's an easier way: $sql = UPDATE $table SET pages = '$PHP_SELF' WHERE session = '$holy_cow'; Be sure you use double-quotes to build the string (so that all variables get interpolated) and single-quotes within

[PHP-DB] SQL update help

2002-09-20 Thread Jas
Here is my statement UPDATE $table SET pages = $PHP_SELF WHERE session = $holy_cow However it will not update I recieve this error: You have an error in your SQL syntax near '/admin/login.done.php WHERE session = 5d44389bd70881131b9ea7573eba34d4' at line 1 Any help would be appreciated Jas --

Re: [PHP-DB] SQL update help

2002-09-20 Thread Jeffrey_N_Dyke
: Subject: [PHP-DB] SQL update help 09/20/2002 03:13 AM

Re: [PHP-DB] SQL update help

2002-09-20 Thread Dave Smith
Jeffrey is right, but here's an easier way: $sql = UPDATE $table SET pages = '$PHP_SELF' WHERE session = '$holy_cow'; Be sure you use double-quotes to build the string (so that all variables get interpolated) and single-quotes within. Any non-numeric value has to be quoted for an SQL