ZODB undo problems
erik.wilsher at iname.com
Wed Sep 19 08:49:51 CEST 2001
I thought transactions in ZODB was 'undoable'. Still calling
db.undo() seems not to work (see below). What have I missed?
PythonWin 2.1.1 (#20, Jul 20 2001, ...
Portions Copyright 1994-2001 Mark ....
>>> from ZODB import FileStorage, DB
>>> storage = FileStorage.FileStorage('slettes.zdb')
>>> db = DB(storage)
>>> conn = db.open()
>>> root = conn.root()
>>> root['r1'] = 0
>>> for i in range(10):
... root['r1'] += 1
>>> undoID = db.undoLog(0,100)['id']
>>>get_transaction().commit() #do I need this?
AMK's standalone ZODB, most recent version.
Anyone out there with good pointers to pages on ZODB programming?
(in addition to those on amk.ca and zope.org).
More information about the Python-list