[ZODB-Dev] Re: Simple Zope Question
Thusjanthan (Nathan) Kubendranathan
tkubendr at cs.sfu.ca
Thu Oct 4 14:10:22 EDT 2007
To all my fellow zope experts,
I am not very proficient in zope. I need to extract all the data from a
data.fs (zope filesystem) into a database. Basically all it contains is
users and notes about users etc. So it's a note taking system.
So basically I am trying to recover some data from a zope.fs file and I have
no clue how to get about it. How do I being to read the data from this file?
So far I have the following:
#!/usr/bin/python
from ZODB.FileStorage import FileStorage
storage = FileStorage('./zope_data.fs', read_only=1)
iter = storage.iterator()
try:
while True:
transaction = iter.next()
for rec in transaction:
print rec
except:
pass
but it gives me a bunch of:
<ZODB.FileStorage.FileStorage.Record instance at 0xb7cdb4ec>
How do I change that into human readable form? Where I can get the notes
associated to the person etc so that I can populate this other database with
this information.
Any help would be much appreciated.
Cheers,
Nathan.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.zope.org/pipermail/zodb-dev/attachments/20071004/9205f1f1/attachment.htm
More information about the ZODB-Dev
mailing list