Hi, I'm trying to code a league table system and I was wondering if there's an easy way of doing this:

$result=mysql_query("UPDATE Championship SET played="++1" WHERE team_name='$home_team'") or die(mysql_error());

The problem lies in the played="++1" part, I can set it to be any integer, but that's not much use, I need it to add 1 to however many games the team have already played. Is there any syntax which would allow me to do this?
Thanks in advance,
Darren.

I've tried played= played +1 as suggested somewhere else. Didn't work.

No, wait, played=played+1 DID work, there was just a " astray.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.