Re: [Zope3-Users] is it possible to copy object b/w two zodb Database
On Jun 11, 2008, at 10:36 AM, rahul bhaskar wrote:
Hi, I am facing some problem with merging two zodb file. is it possible to open two zodb Database at a time and copy object from one to another.
Yes, using the export/import mechanism. Jim -- Jim Fulton Zope Corporation
On Wednesday 11 June 2008, Jim Fulton wrote:
On Jun 11, 2008, at 10:36 AM, rahul bhaskar wrote:
Hi, I am facing some problem with merging two zodb file. is it possible to open two zodb Database at a time and copy object from one to another.
Yes, using the export/import mechanism.
Stupid question: Which one? I tried straight xmlpickle and got some errors randomly. Regards, Stephan -- Stephan Richter Web Software Design, Development and Training Google me. "Zope Stephan Richter"
On Jun 11, 2008, at 4:22 PM, Stephan Richter wrote:
On Wednesday 11 June 2008, Jim Fulton wrote:
On Jun 11, 2008, at 10:36 AM, rahul bhaskar wrote:
Hi, I am facing some problem with merging two zodb file. is it possible to open two zodb Database at a time and copy object from one to another.
Yes, using the export/import mechanism.
Stupid question: Which one? I tried straight xmlpickle and got some errors randomly.
I was referring to the binary export/import, which is the only one supported by ZODB, afaik, although it's been a very long time since I looked at that code. Jim -- Jim Fulton Zope Corporation
On Wednesday 11 June 2008, Jim Fulton wrote:
Stupid question: Which one? I tried straight xmlpickle and got some errors randomly.
I was referring to the binary export/import, which is the only one supported by ZODB, afaik, although it's been a very long time since I looked at that code.
Where is the code? I could nto find anything quickly? Regards, Stephan -- Stephan Richter Web Software Design, Development and Training Google me. "Zope Stephan Richter"
On Jun 11, 2008, at 7:51 PM, Stephan Richter wrote:
On Wednesday 11 June 2008, Jim Fulton wrote:
Stupid question: Which one? I tried straight xmlpickle and got some errors randomly.
I was referring to the binary export/import, which is the only one supported by ZODB, afaik, although it's been a very long time since I looked at that code.
Where is the code? I could nto find anything quickly?
ZODB/ExportImport.py This defines a class that gets mixed into ZODB.Connection.Connection. Jim -- Jim Fulton Zope Corporation
Jim Fulton wrote at 2008-6-11 15:18 -0400:
On Jun 11, 2008, at 10:36 AM, rahul bhaskar wrote:
Hi, I am facing some problem with merging two zodb file. is it possible to open two zodb Database at a time and copy object from one to another.
Yes, using the export/import mechanism.
Another option is to mount both ZODB's and then copy the objects. It is necessary to decouple the copy from its source before it can be stored in the target. Apparently, "copy.deepcopy" is able to reliably decouple. -- Dieter
participants (3)
-
Dieter Maurer -
Jim Fulton -
Stephan Richter