> Also I concluded that because all the references are replaced by mongodb 
id's it is not possible to say 
> dump a table with references in one database and then restore it on 
mongodb.

Neither you can (or should) with other adapters, for example, postgres. 
Here's section of the book about that issue:

"... In order to make a record uniquely identifiable across databases, they 
must:

   - have a unique id (UUID),
   - have an event_time (to figure out which one is more recent if multiple 
   copies),
   - reference the UUID instead of the id.

..."
> ... Because you have no relation between the records anymore.

There's a possible bug with the import feature or the mongodb adapter. 
Maybe you can file an issue in the project page adding as many info as 
possible to reproduce the problem. While changing the id numbers, the id 
references should be preserved between records.

I am curious about the reason, would het not be smarter to just keep the 
> original id's ? Afterall mongodb uses _id. So it does not bite. 
>

I don't think it is a good idea because that way, DAL would have to deal 
with two auto-generated record identifiers (adding redundant and confusing 
id fields) for any database operation.

-- 

--- 
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/groups/opt_out.


Reply via email to