#2 ignores db.branch.name.unique = True db.branch.name.notnull = True
because they are set after the table definition. You can only override attributes that are not used at table definition. On Mar 2, 11:09 am, goutham <[email protected]> wrote: > whats the diff between > > ####### case 1 ######### > db.define_table('branch', > Field('name','string', unique = True, notnull = True), > Field('content','list:string')) > > ###### case 2 ####### > db.define_table('branch', > Field('name','string'), > Field('content','list:string')) > > db.branch.name.unique = True > db.branch.name.notnull = True > ############# > > in case 2 the database is not added with the unique and notnull > constraints .. why is this happening whats the diff..

