So I have a child object with a many to one relationship with a parent. This parent has a DATE field which is set to not nullable, and has a columnDefinition to create a default date. I am new to hibernate/jpa...I imagine when inserting a parent object into the database it will automatically insert a date for me.
However..I create a parent object...set it onto my child object, and save the child. In a ManyToOne relationship, when saving a child object, it will automatically insert a row for the parent object. This is failing. It keeps saying can't insert null for date, but shouldn't it automatically insert the date for me per the columnDefinition? if I set the date to nullable = true everything works fine..Sorry I can't post relevant code it is work related :/.