ok, i had a little revelation in my sleep, have both fields IS_EMPTY_OR 
with IS_IN_DB, but how can i add the extra condition that one or the other 
must not be empty?

db.define_table('payments',
    Field('user_id', db.auth_user, requires=IS_EMPTY_OR(IS_IN_DB(db, 
db.auth_user.id, '%(last_name)s, %(first_name)s (%(id)s) | %(email)s | 
%(city)s %(zip)s')), writable=False, readable=False),
    Field('firm_id', db.firms, requires=IS_EMPTY_OR(IS_IN_DB(db, 
db.firms.id, '%(firm_name)s (%(id)s) | %(city)s | %(zip)s | 
%(telephone)s')), writeable=False, readable=False),

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to