Cannot obtain DBObject for transient instance, save a valid instance first with grails and mongodb -


cannot obtain dbobject transient instance, save valid instance first.

i using grails 2.2.1 , mongodb 1.2.0. there domain below.

class person{  static mapwith = "mongo"  static hasmany = [categories:category , address:address];   string firstname;  string lastname;  string emailid;  int age;  string contactnumber;  string sex;  byte [] personimage;  string identity;  static constraints = {     identity nullable: true , inlist:["driving license"] , unique: true;     emailid email: true , unique: true     contactnumber unique: true   } } 

when going save giving error.


Comments

Popular posts from this blog

timeout - Handshake_timeout on RabbitMQ using python and pika from remote vm -

gcc - MinGW's ld cannot perform PE operations on non PE output file -

c# - Search and Add Comment with OpenXML for Word -