iR00T Posted July 30, 2008 Share Posted July 30, 2008 QUERY ERROR: Column count doesn't match value count at row 1 Query was INSERT INTO users (username, login_name, userpass, level, money, crystals, donatordays, user_level, energy, maxenergy, will, maxwill, brave, maxbrave, hp, maxhp, location, gender, signedup, email, bankmoney, creditcard) VALUES( 'NPC', '12132123', md5('3213232'), 10, 12211, 0, 0, 0, 30, 30, 100, 100, 23, 23, 550, 550, 1, 'Male', unix_timestamp(), '3232132', -1) i get that when i try to create a user on my game :S...well i added credit card but as you see it adds tat info in right ther ei mean on the create user thing it dont say Creditcard: how much xD so would that be the problem even tho the code says -1 at the end...? Quote Link to comment Share on other sites More sharing options...
Floydian Posted July 31, 2008 Share Posted July 31, 2008 Re: Create user problem There's 22 of these: username, login_name, userpass, level, money, crystals, donatordays, user_level, energy, maxenergy, will, maxwill, brave, maxbrave, hp, maxhp, location, gender, signedup, email, bankmoney, creditcard And 21 of these: 'NPC', '12132123', md5('3213232'), 10, 12211, 0, 0, 0, 30, 30, 100, 100, 23, 23, 550, 550, 1, 'Male', unix_timestamp(), '3232132', -1 Somewhere, you missed a value. Hence the column count error. ;) Quote Link to comment Share on other sites More sharing options...
AlabamaHit Posted July 31, 2008 Share Posted July 31, 2008 Re: Create user problem I just looked through.... All thats wrong is your not placing the Location. You need to check the query. And add it to add a Location. Quote Link to comment Share on other sites More sharing options...
iR00T Posted July 31, 2008 Author Share Posted July 31, 2008 Re: Create user problem k so i should add some where in those to lines the location ..? and it would be 1 for default -.- xD Quote Link to comment Share on other sites More sharing options...
The Ace Posted July 31, 2008 Share Posted July 31, 2008 Re: Create user problem I looked through and it seems you're missing the default credit card. Location is there, after maxhp. I'd use this: 'NPC', '12132123', md5('3213232'), 10, 12211, 0, 0, 0, 30, 30, 100, 100, 23, 23, 550, 550, 1, 'Male', unix_timestamp(), '3232132', -1, -1 or whatever you want the default credit card amount to be.....most likely -1. Quote Link to comment Share on other sites More sharing options...
Floydian Posted July 31, 2008 Share Posted July 31, 2008 Re: Create user problem I can't hardly stand it.... signedup, email, bankmoney, creditcard You have a unix timestamp, you have a series of numbers, which is obviously bankmoney, and a -1 What's missing in that? THE EMAIL lol Quote Link to comment Share on other sites More sharing options...
The Ace Posted July 31, 2008 Share Posted July 31, 2008 Re: Create user problem Ah, yes. :oops: lol. I was too focused about the "credit card" issue!!! GGL. 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.