• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

null value to database table from JForm

 
Gokcen Guner
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Im working on a project similar to custom database app tutorial of NetBeans (http://www.netbeans.org/kb/docs/java/gui-db-custom.html)

When I try to add new record to detail table i get he error:



There are a lot of errors too, but that may be enough. If not i can post it too.
I've just followed the instructions in the tutorial to trace the problem and they are all the same. I couldn't find the problem.
 
Rob Spoor
Sheriff
Pie
Posts: 20492
54
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Gokcen Guner wrote:Internal Exception: com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException: Column 'offense' cannot be null

Apparently, in your database table, you've specified that column "offense" cannot have any null values.

Moving to JDBC.
 
Gokcen Guner
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanks for reply. Eventually Ive found why the data didnt go to database from JForm.
 
himanshu rai
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
@Gokcen Guner
Im having the same problem, how did solve it?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic