gorm - grails, loading domain from db when fields contains null causes setters to fail -
this problem fields declared double , null in database. using findallby receive list fails if of fields null. tried changing type double problems when arithmetics on them. if value null double can't decide converter should use. don't know if there way convert nulls in domain before set. example of error:
caused by: org.hibernate.propertyaccessexception: null value assigned property of primitive type setter of com.buffer.prodbuffer.makeinquiry
you should use double
in entities/domains; unless have nullable: false
constraint @ work, it's practice, nonetheless.
however, need handle null
in calculations, making 0 or 1, know better. more suggestions, post code snippet.
Comments
Post a Comment