List:General Discussion« Previous MessageNext Message »
From:Paul DuBois Date:March 14 2003 5:29pm
Subject:Re: Updat not Updating
View as plain text  
At 16:18 +0000 3/14/03, Andrew wrote:
>Can anyone tell me why this is not updating records for this table?
>
>mysql_connect("$DBHost","$DBUser","$DBPass");
>mysql("$DBName","UPDATE items
>SET ItemSKU='$ItemSKU',
>ItemName='$ItemName',
>ItemDescription='$ItemDescription',
>PostCode='$PostCode',
>Category='$Category',
>CityID='$CityID'
>CTelephone='$CTelephone'
>Cfax='$Cfax'
>Cemail='$Cemail'
>Caddress='$Caddress'
>Cfax='$CTown'
>Cwww='$Cwww'
>WHERE ItemID='$ItemID'");
>
>Andrew

We cannot, but MySQL and PHP can.

1) Check the return values of the function calls to make sure they
work.  As written, you have no way of knowing.

2) When an error occurs, print the value of mysql_error() to see what
the error is.


-- 
Paul DuBois, paul@stripped
http://www.kitebird.com/
sql, query
Thread
Updat not UpdatingAndrew14 Mar
  • Re: Updat not UpdatingPaul DuBois14 Mar
  • Re: Updat not Updatingnobody14 Mar
    • RE: Updat not UpdatingAndrew14 Mar
      • Re[2]: Updat not Updatingnobody14 Mar
      • RE: Updat not UpdatingPaul DuBois14 Mar
        • RE: Updat not UpdatingAndrew14 Mar
          • RE: Updat not UpdatingPaul DuBois14 Mar
          • Re: Updat not UpdatingBrian McCain14 Mar
            • RE: Updat not UpdatingAndrew15 Mar
              • Re: Updat not UpdatingSime15 Mar
                • Re: Updat not UpdatingDon Read16 Mar