Re: moving On Wed, 30 Apr 2008 18:01:21 +0200, val <vlepage@aol.com> wrote:
> On 30 avr, 17:34, Luuk <L...@invalid.lan> wrote:
>
>> an UPDATE should do it, give us what you tried, and the error message(s)
>> you got...
>
> I thus have to show how unskilled I am with mysql...
>
> Here it is. The last one I tried is this :
>
> $sql = "UPDATE dbase
> SET field1= (SELECT field1 WHERE NAME='$old_name')
> WHERE NAME ='$new_name'";
>
>
> $old_name contains 't1' and $new_name contains 't3'
> (I use PHP to send the request, through the mysql_db_query function.
>
> 1064: Erreur de syntaxe près de 'WHERE NAME='t1') WHERE NAME='t3''
SET field1= (SELECT field1
FROM what????
WHERE NAME='$old_name')
--
Rik Wasmus |