开发者

Add numbers within mysql column

I have a php script that I'm using to rank football teams. Basically, every time you click on the picture of a football team, the data is input into a mysql database. I have a column for the number of times the football team has been selecte开发者_高级运维d. How do I add 1 to the number in that column every time the football team is clicked, from within the php. Right now I am using an UPDATE command, but I can't get it to work. Thanks for suggestions


 UPDATE click_table SET clicks = clicks + 1 WHERE team = <team>;
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜