List:General Discussion« Previous MessageNext Message »
From:Nicolas Verhaeghe Date:April 21 2006 9:50pm
Subject:RE: WHERE doesn't work
View as plain text  
Magic quotes replaces the ' with '' so that when you execute an SQL query,
it is encoded properly.

Or else someone could put a single quote in a form field and screw up your
database.

I do not like magic quote myself.

But we're going OT.

Echo the UPDATE query itself and then copy/paste it here that way we'll see
what is wrong.

Maybe the $id variable is not replaced with the proper content.

-----Original Message-----
From: Tom Lobato [mailto:tomlobato@stripped] 
Sent: Friday, April 21, 2006 2:31 PM
To: mysql@stripped
Subject: Re: WHERE doesn't work



>From: "Nicolas Verhaeghe" <nicolas@stripped>
>Ok but what is the problem then?

    WHERE doesn't work. Iwrite WHERE in the command for UPDATE exactily one 
record, defined by id = $id, and mysql server UPDATE all the records in the 
table.

>Also are you taking care of converting the single quotes or do you have 
>magic quotes set to on?

    What do you mean with "converting the single quotes"?
    I dont know what is magic quotes, but, from phinfo.php:

magic quotes gpc        on on
magic quotes runtime  off off
magic quotes sybase   off off


    Tom 


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/mysql?unsub=1

Thread
WHERE doesn't workTom Lobato20 Apr
  • Re: WHERE doesn't workBarry21 Apr
  • Re: WHERE doesn't workPeter Brawley23 Apr
  • Re: WHERE doesn't workTom Lobato23 Apr
    • Re: WHERE doesn't workPeter Brawley23 Apr
  • Re: WHERE doesn't workTom Lobato23 Apr
RE: WHERE doesn't workJay Blanchard20 Apr
  • Re: WHERE doesn't workTom Lobato20 Apr
RE: WHERE doesn't workGeorge Law20 Apr
Re: WHERE doesn't workTom Lobato21 Apr
  • RE: WHERE doesn't workNicolas Verhaeghe21 Apr
    • Re: WHERE doesn't workTom Lobato21 Apr
      • RE: WHERE doesn't workNicolas Verhaeghe21 Apr
      • RE: WHERE doesn't workNicolas Verhaeghe21 Apr
        • Re: WHERE doesn't workTom Lobato21 Apr
          • RE: WHERE doesn't workNicolas Verhaeghe21 Apr
            • Re: WHERE doesn't workTom Lobato22 Apr
              • Re: WHERE doesn't workMichael Stassen22 Apr
  • RE: WHERE doesn't workNicolas Verhaeghe21 Apr
Re: WHERE doesn't workTom Lobato21 Apr
Re: WHERE doesn't workTom Lobato21 Apr
Re: WHERE doesn't workTom Lobato21 Apr
RE: WHERE doesn't workJay Blanchard21 Apr
  • Re: WHERE doesn't workTom Lobato21 Apr
Re: WHERE doesn't workTom Lobato24 Apr