db.voter.voterid.requires=IS_NOT_IN_DB(db
((db.voter.lastname==request.vars.lastname)&
(db.voter.firstname==request.vars.firstname)),'voter.voterid'))


On Dec 13, 2:28 pm, DenesL <[email protected]> wrote:
> Now I am the confused one.
>
> Help me understand using the following example. Given:
>
> db.define_table('voter',
>   SQLField('lastname'),
>   SQLField('firstname'),
>   SQLField('voterid'))
>
> What would the requires statement look like to make sure that no
> combination of lastname, firstname, voterid is repeated in this
> table?.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web2py Web Framework" 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
-~----------~----~----~----~------~----~------~--~---

Reply via email to