[Zope-dev] File.py to RDBMS

Christopher Petrilli petrilli@digicool.com
Thu, 26 Aug 1999 10:45:35 -0400


> Hello,
> 
> I want to store uploaded files in a RDBMS (Sybase 11) instead in
> ZODB3. How can I accomplish that ? I already read Image.py but didn't
> get the clue...

Some thoughts, since I've wondered about similar things myself, mostly to
keep the size of the ODB manageable under heavy use.  So, what you would
need to do is create a "proxy" object in the ODB that has information
pertaining to the file.  It would know how to get the information out of the
RDBMS (or even file system?) and pass it back.  It should probably also
cache things reasonably.  It would also need to support BLOBS probably in
the database (I only know DB2 and Oracle for this, and I'd rather not admit
to the latter :-).    Honestly, it shouldn't be that hard, and I think such
"proxy" objects could be useful for any site that has large files as well
(for example, I've talked with one customer who needs to provide access to a
couple hundred gig of data, not something you'd want in the ZODB honestly.).

Chris

--
| Christopher Petrilli        Python Powered        Digital Creations, Inc.
| petrilli@digicool.com                             http://www.digicool.com