This is the Mongo Adapter types definition, I see no type 'dict' maybe it
needs a new type "document'.
class MongoDBAdapter(NoSQLAdapter):
uploads_in_blob = True
types = {
'boolean': bool,
'string': str,
'text': str,
'password': str,
'blob': str,
'upload': str,
'integer': long,
'double': float,
'date': datetime.date,
'time': datetime.time,
'datetime': datetime.datetime,
'id': long,
'reference': long,
'list:string': list,
'list:integer': list,
'list:reference': list,
}
On Wed, Mar 7, 2012 at 3:51 PM, rdodev <[email protected]> wrote:
> Folks,
>
> I'm trying to define a mongo table in db.py that looks something like this:
>
> {
> field1 : "super",
> field2 : "super",
> things = { this : "stuff", that = "stuff" },
> field3 : "Give me a call"
> }
>
> defining fields1-3 is easy, but what's the syntax to build 'things' which
> itself is a dictionary (see above)? Your help is much appreciated.
>
--
Bruno Rocha
[http://rochacbruno.com.br]