you do not need the IS_IN_DB if you use format.
db.define_table('category',Field('name','string'),format='%(name)s')
db.define_table('note',
Field('description','string'),
Field('created_on','date'),
Field('category',db.category))
On Mar 8, 5:42 am, villas <[email protected]> wrote:
> Hi Giovanni
>
> Something like this should help:
> db.note.category.requires = IS_IN_DB(db, db.category.id, '%(name)s')
>
> This tutorial section gives an
> example:http://web2py.com/book/default/section/3/6
>
> Regards,
> -David
--
You received this message because you are subscribed to the Google Groups
"web2py-users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/web2py?hl=en.