On Fri, 17 Feb 2006 12:32:52 +0100, Rene Pijlman wrote: > Dan Stromberg: >>> My first attempt would be: a BTree with the word as key, and a 'list of >>> filenames' as value. >>> http://www.zope.org/Wikis/ZODB/FrontPage/guide/node6.html#SECTION000630000000000000000 >> >>This is basically what I'm doing now, > > Right. My second attempt would be: a BTree with the word as key, and a > BTree of filenames as value (or some other persistent container type > that's not (un)serialized as a whole when only one element changes).
This is a fantastic mapping from the problem domain to the solution domain, but... I don't know how to do a btree of btrees in python... Nor any other database of databases. Would ZODB let me do that? I'm puzzled, because: [EMAIL PROTECTED]:~$ python Python 2.4.2 (#2, Sep 30 2005, 21:19:01) [GCC 4.0.2 20050808 (prerelease) (Ubuntu 4.0.1-4ubuntu8)] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> d1={} >>> d={} >>> d[d1] = '' Traceback (most recent call last): File "<stdin>", line 1, in ? TypeError: dict objects are unhashable >>> Would I have to come up with some sort of hashable dict first? -- http://mail.python.org/mailman/listinfo/python-list