Paddy Posted April 13, 2008 Posted April 13, 2008 Don't know if this is the right place to put it but i was wondering if any one could help me out with this query since i don't quite understand these things but i learn very quickly! QUERY ERROR: Unknown column 'attacks_won' in 'field list' Query was UPDATE users SET attacks_won=attacks_won+1 WHERE userid=1 i guess you know where this has shown up ''just after wining a fight'' Thanks In advanced Quote
Guest Anonymous Posted April 13, 2008 Posted April 13, 2008 Re: QUERY ERROR Looks like you need to add the column "attacks_won" to the users table: ALTER TABLE `users` ADD `attacks_won` INT UNSIGNED NOT NULL DEFAULT '0'; Quote
Paddy Posted April 13, 2008 Author Posted April 13, 2008 Re: QUERY ERROR Duplicate column name 'attacks_won' still the same ahh no not the same QUERY ERROR: Unknown column 'attacks_total' in 'field list' Query was UPDATE users SET attacks_total=attacks_total+1 WHERE userid=1 Quote
Guest Anonymous Posted April 13, 2008 Posted April 13, 2008 Re: QUERY ERROR Hmm, odd - PM me the structure of your users table (phpMyAdmin - Export - **NO DATA**)... I'm curious about this.. Might be an idea to post a snippet of the code as well - 10 or so lines either side of the line containing the error. Quote
Floydian Posted April 13, 2008 Posted April 13, 2008 Re: QUERY ERROR Now it sounds like you need to add the attacks won column to the users table ;) Rinse and repeat if necessary ;) Quote
Paddy Posted April 14, 2008 Author Posted April 14, 2008 Re: QUERY ERROR Yes Thats What I did :-) And it worked thanks too nyna Quote
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.