On Wednesday 24 July 2013 11:52:36 Alan Etkin wrote:

> 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.
..."


Agreed, but because mongodb is a nosql you could push this away to the 
developer. (What I am not abviously)


> ... 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 going to see if I can create a testcase to reproduce the error, maybe its 
because of the order of the data in db.py


> 
#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 did so forget about that :-) Thanks for reminding me. 


And thanks for taking the time to answer me. Its very much appreciated.

--  --- 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[1].  





--------
[1] https://groups.google.com/groups/opt_out

-- 

--- 
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