I am well aware of the usage of IS_IN_DB in web2py however I want to select some particular values of the table in drop down.
Like presently this attribute selects all users registered in the application.
db.Field('selected_users','string',requires=IS_IN_DB(db,db.auth_user.id,'%(Name)s',zero=None))
However I just want to list down the verified users i.e.
the query should be:
query=((db.auth_user.id>0) & (db.auth_user.registration_key==""))
How do I fit it with the model:
Is this correct? Doesn't seem to work in my case though.
db.Field('selected_users','string',requires=IS_IN_DB(query,db.auth_user.id,'%(Name)s',zero=None))
Thanks in advance,
Regards,
Akash