I will try my best here to explain what I'm after -- I'm clueless on how to 
do it.  I added a custom field to db.auth_user called team_name.  Each 
registered user should have a unique team name.  

In a seperate table, I have a team name and a list of challenges, 
1,2,3,etc.    I want the team name of this table to reference the team_name 
in auth_user.  I've tried several different variations -- but each time I 
seem to either hang web2py or I get "keyed tables can only reference other 
keyed tables".
 
my additions to auth_user look like 
this: auth.settings.extra_fields['auth_user'] = [Field('team_name')]
my other table definition looks like this at the moment -- but I've tried 
other ways:
db.define_table('t_teams',
    Field('name', db.auth_user.team_name),
    Field('f_chal1', type='boolean',
          label=T('Chal1')),
    Field('f_chal2', type='boolean',
          label=T('Chal2')),
    Field('f_chal3', type='boolean',
          label=T('Chal3')),
    Field('f_chal4', type='boolean',
          label=T('Chal4')),

Thanks again for all the help.

Chris



-- 

--- 
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