This week's book giveaway is in the OCP forum.
We're giving away four copies of OCP Java SE 8 Programmer II Exam Study Guide and have Kathy Sierra, Bert Bates, & Elizabeth Robson on-line!
See this thread for details.
Win a copy of OCP Java SE 8 Programmer II Exam Study Guide this week in the OCP forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

sql insert statement giving sqlcode: -206 sqlstate: 42703  RSS feed

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi while inserting data from one database table to another database table i am am able to fetch recors from source database but while inserting into target database i am getting error sqlcode: -206

sqlstate: 42703

when i checked out error msg but even then i am unable to correct it...please help..

code:


rowsAffected= gffUserDet.executeUpdate(insertSql1);
 
Ranch Hand
Posts: 40
Chrome Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are you getting an exception?
Can you please post the whole trace of the error..
 
Ranch Hand
Posts: 147
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
DB2 has that sqlstate and code defined as "An undefined column or parameter name was detected."

So maybe ensure your column names match up to those in the table?

Also, might want to put a space between the keyword "VALUES" and the opening paren in your value list. Driver may be looking for a space there.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!