|
Rune Hansen
rune.hansen at scanmine.com
Thu Dec 2 15:19:21 EST 2004
What has this got to do with mod_python you might ask. Good question. I
found that gdbm is faster that dbhash - the app won't be running on
windows anyway...
Python 2.3.4 (#1, Dec 1 2004, 15:27:31)
[GCC 3.2.3 20030502 (Red Hat Linux 3.2.3-42)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import gdbm
>>> db = gdbm.open("test.dmb","w")
>>> db["a"] = "rune"
>>> del db["a"]
>>> db.reorganize()
>>> db.close()
Python 2.3.4 (#1, Dec 1 2004, 15:27:31)
[GCC 3.2.3 20030502 (Red Hat Linux 3.2.3-42)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import gdbm
>>> db = gdbm.open("mp_session.dbm","w")
>>> db.reorganize()
Traceback (most recent call last):
File "<stdin>", line 1, in ?
gdbm.error: Reorganize failed
>>> import whichdb
>>> whichdb.whichdb("mp_session.dbm")
'gdbm'
Anyone got any idea why reorganize() fails on a gdbm database created
by Session.Dbmsession() ?
regards
/rune
|