column doesn't match value count at row 1

  • buzzby365
  • Proficient
  • Proficient
  • buzzby365
  • Posts: 288

Post 3+ Months Ago

i have updated the database and changed some fields and now i am getting this message.

"column doesn't match value count at row 1"

i am so unsure as to what to do. i have looked at the database and the fields and they match. in my database i have ID on row 1 and NAME on row 2 (not in caps). why is this message coming up?
  • Anonymous
  • Bot
  • No Avatar
  • Posts: ?
  • Loc: Ozzuland
  • Status: Online

Post 3+ Months Ago

  • Rabid Dog
  • Web Master
  • Web Master
  • User avatar
  • Posts: 3245
  • Loc: South Africa

Post 3+ Months Ago

Your SQL is probably

Code: [ Select ]
INSERT INTO table VALUES('name')


or something like that.

The value count doesn't match the number of rows you are trying to insert into

try
Code: [ Select ]
INSERT INTO table VALUES('','name)

or try

INSERT INTO table(name) VALUES('string name')
  1. INSERT INTO table VALUES('','name)
  2. or try
  3. INSERT INTO table(name) VALUES('string name')


this should work, I have a feeling you have set the id row to auto increment and are not inserting values into, that is why you are getting the error.

Let me know if this works

Post Information

  • Total Posts in this topic: 2 posts
  • Users browsing this forum: No registered users and 78 guests
  • You cannot post new topics in this forum
  • You cannot reply to topics in this forum
  • You cannot edit your posts in this forum
  • You cannot delete your posts in this forum
  • You cannot post attachments in this forum
 
 

© 1998-2014. Ozzu® is a registered trademark of Unmelted, LLC.