I might be completly wrong but shouldn´t it be like this:
db.define_table('person', Field('name'), Field('groupe',
'list:reference groupe'))
db.define_table('groupe',Field('groupname'))
db.groupe(db.person.id<3).update(groupe=1)
If one users can be in many groups you get a many-to-many relationship
and you need a third table to now to what group a user belongs.
Kenneth
I'm trying to update a 'list:reference' field programaticaly, but this
doesn't work so far.
Say I have this model:
db.define_table('person', Field('name'))
db.define_table('groupe',Field('groupname'), Field('groupusers',
'list:reference person'))
assume I have already entered three persons, with ids 1,2,3 and, also
defined a group with id=1
Then
db.groupe(db.groupe.id==1).update(groupusers=[1,2])
doesn't change the record. Does someone see what I'm doing wrong?
Thanks in advance for any cue on this.
Andre