The-Last-Escape Posted May 2, 2007 Share Posted May 2, 2007 Hi, I have a table named brokers and am trying to add numbers from a menu to an existing number in a field named value_votes . I tried it with the UPDATE command in sql but this just replaced my old number not added to it. I know I need to do something along these lines: UPDATE brokers SET value_votes WHERE value_votes = existing number + new number from form , that last little bit is over my head, can anybody help me with that syntax Quote Link to comment Share on other sites More sharing options...
trq Posted May 2, 2007 Share Posted May 2, 2007 UPDATE brokers SET value_votes = value_votes + 1 WHERE id = 5; This would add one to value_notes in the record with an id of 5. Quote Link to comment Share on other sites More sharing options...
The-Last-Escape Posted May 2, 2007 Author Share Posted May 2, 2007 Thanks Trope your the true King Of Kings Quote Link to comment Share on other sites More sharing options...
trq Posted May 2, 2007 Share Posted May 2, 2007 Please... stop calling me Trope. :-) Quote Link to comment Share on other sites More sharing options...
The-Last-Escape Posted May 2, 2007 Author Share Posted May 2, 2007 Sorry I mean Thorpe Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.