dmcdaid Posted May 11, 2007 Share Posted May 11, 2007 Need Help when i try to give an item to a user via staff panel QUERY ERROR: Column count doesn't match value count at row 1 Query was INSERT INTO inventory VALUES('',13,1,1,'0','N') Heres the code $db->query("INSERT INTO inventory VALUES('',{$_POST['item']},{$_POST['user']},{$_POST['qty']},'0','N')"); Quote Link to comment Share on other sites More sharing options...
Silver Posted May 11, 2007 Share Posted May 11, 2007 Re: help post up the fields in your sql table for items Quote Link to comment Share on other sites More sharing options...
dmcdaid Posted May 11, 2007 Author Share Posted May 11, 2007 Re: help itmid itmtype itmname itmdesc itmbuyprice itmsellprice itmbuyable effect1_on effect1 effect2_on effect2 effect3_on effect3 weapon armor Quote Link to comment Share on other sites More sharing options...
Silver Posted May 11, 2007 Share Posted May 11, 2007 Re: help gah, i meant inventory, sorry...plz post inventory fields Quote Link to comment Share on other sites More sharing options...
dmcdaid Posted May 11, 2007 Author Share Posted May 11, 2007 Re: help inv_id inv_itemid inv_userid inv_qty Quote Link to comment Share on other sites More sharing options...
Silver Posted May 11, 2007 Share Posted May 11, 2007 Re: help $db->query("INSERT INTO inventory VALUES('',{$_POST['item']},{$_POST['user']},{$_POST['qty']})"); try that Quote Link to comment Share on other sites More sharing options...
dmcdaid Posted May 11, 2007 Author Share Posted May 11, 2007 Re: help Works a charm Thanks Quote Link to comment Share on other sites More sharing options...
Silver Posted May 11, 2007 Share Posted May 11, 2007 Re: help yw 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.