java - Grails nullable:true not working after modifying domain class -


i have domain class few fields. application running , had add 2 more fields domain class marked nullable:

class somedomain{    // fields beginning    .............    // 2 fields added afterwards    string fielda    string fieldb    static constraints = {      // constraints on initial fields      ...............      // constraints on fields added afterwards      fielda(nullable: true)      fieldb(nullable: true)    }  } 

but when run this, see fields added mysql table. don't have nullable constraint. not allowing nulls in fields. reason , there way solve this. can edit mysql tables directly add nullable property 2 fields. want know why create 2 fields in table, failed add null constraint(so in future can avoid such errors).

i using grails 2.2.1.


Comments

Popular posts from this blog

Android : Making Listview full screen -

javascript - Parse JSON from the body of the POST -

javascript - Chrome Extension: Interacting with iframe embedded within popup -