> The modificador_eventos field will be a json with a list format, so im 
> trying to insert a list in it using this code:
>
> eventos = json.loads(eventos)
> lista = [eventos, eventos, eventos]
> respuesta = db(db.tarifas.id == 
> id).validate_and_update(modificador_eventos=lista).as_dict()
>
> Where var eventos is:
>
> {
>     "nombre": "qq",
>     "fecha_inicio": "12/12/2012",
>     "fecha_fin": "14/12/2012",
>     "existencias": "3",
>     "descuento": "21"
> }
>
> When i try to do that i receive this exception:
>
>   File "/usr/local/lib/python2.7/dist-packages/gunicorn/workers/sync.py", 
> line 130, in handle
>

I belive that a list:string field requires you to provide with a python 
list object containing string values. Doing otherwise should throw an 
exception. I'd try to use the json field type to store JSON.
 

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
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 web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to