Il 01/04/2012 23:23, bussiere adrien ha scritto:
ok i see the example :
>>>  db.define_table('tag',Field('name'),format='%(name)s')
>>>  db.define_table('product',
         Field('name'),
         Field('tags','list:reference tag'))
>>>  a=db.tag.insert(name='red')
>>>  b=db.tag.insert(name='green')
>>>  c=db.tag.insert(name='blue')
>>>  db.product.insert(name='Toy Car',tags=[a,b,c])
*but if after i make :*
d=db.tag.insert(name='purple')

how to add d to db.product ? with a,b,c who were already here ?

I use to:

1. extract the values in a variable
2. append the new value to the list variable
3. update the value in table

    M.


Regards
Bussiere

*
*

Reply via email to