Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

SQL error:java.sql.SQLException: ORA-01008: not all variables bound

 
Reggie McDougal
Ranch Hand
Posts: 69
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm getting ORA-01008 when I run the following INSERT
statement, product_id is a PK and a number column, as I am using
"setString" should this be a long when I INSERT?

I'm using Oracle 8.1

REG




[edited to remove whitespace from beginning of lines so page doesn't scroll right]
[ January 27, 2005: Message edited by: Jeanne Boyarsky ]
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 35279
384
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Reggie,
It's better to use a long because it clearly expresses the intent of the setter and eliminates the possiblity of a database exception caused by an poorly formatted a string.
 
Adeel Ansari
Ranch Hand
Posts: 2874
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You had 6 twice and didn't set something for 7.
cheers.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic