java.sql.SQLException: Column count doesn’t match value count at row 1

The problem is not the id column.

From the statement it looks like you have quotes around all columns. Therefore it seems to the SQL, that you have only one column

'"title","url","age"'

What you might want to have is

"insert into table(title, url, age) values ('" + title + "','" + url + "'," + age + ")"

or even better yet, since it is a prepared statement

"insert into table(title, url, age) values (?, ?, ?)"

Leave a Comment