RE: [PHP-DB] Huw do I perform update? I missed the accual code bit.. sorry
| From: | Brian Paulson | Date: | Wed, 26 Sep 2001 17:40:38 +0000 |
| Subject: | RE: [PHP-DB] Huw do I perform update? I missed the accual code bit.. sorry | ||
| References: | 1 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-12746@lists.php.net to get a copy of this message | ||
Id news_id an integer?
$query = "UPDATE dvd.news_categories SET
newscategory='$newscategory',
newscat_status='$newscat_status' WHERE newscat_id='$newsid'";
^ if this is an
integer in the datebase then it wont update proproly.
Should look like this
$query = "UPDATE dvd.news_categories SET
newscategory='$newscategory',
newscat_status='$newscat_status' WHERE newscat_id = $newsid";
Hope this helps
Thank You
Brian Paulson
Sr. Web Developer
The Pueblo Chieftain Online
bpaulson@chieftain.com
http://www.chieftain.com
> -----Original Message-----
> From: Rick Emery [mailto:remery@excel.com]
> Sent: Wednesday, September 26, 2001 10:59 AM
> To: php-db@lists.php.net
> Subject: RE: [PHP-DB] Huw do I perform update? I missed the
> accual code bit.. sorry
>
>
> What does table look like?
> What does preceding code look like?
> What error message are you getting?
>
> Try printing the value of $query. What does it look like?
> Copy/paste that into mysql directly; what error do you get?
>
> -----Original Message-----
> From: Tommy Nilsson [mailto:tommyhome@softhome.net]
> Sent: Wednesday, September 26, 2001 11:14 AM
> To: php-db@lists.php.net
> Subject: [PHP-DB] Huw do I perform update? I missed the
> accual code bit.. sorry
>
>
> Sorry,:
> This is my query:
> $query = "UPDATE dvd.news_categories SET
> newscategory='$newscategory',
> newscat_status='$newscat_status' WHERE newscat_id='$newsid'";
>
> but it doesn't seem to work.
>
> help anyone?
>
> //Tommy
>
> --
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-db-unsubscribe@lists.php.net
> For additional commands, e-mail: php-db-help@lists.php.net
> To contact the list administrators, e-mail:
> php-list-admin@lists.php.net
>
>
>