[FRPythoneers] Pickling into BLOB field in Windows into Access MDB

Sean Reifschneider jafo at tummy.com
Thu Oct 4 23:26:44 MDT 2001


On Thu, Oct 04, 2001 at 03:09:18PM -0600, Sue Giller wrote:
>The object returned from the OLE field seems to be a buffer type.  
>
><read-write buffer ptr 0167B3B4, size 44 at 0167B398>

Try doing a "dir()" on that object to see what it can do.  Maybe it's list
of methods will give you a clue as to how to extract it.  For example:

   >>> l = [1, 2, 3]
   >>> print dir(l)
   ['append', 'count', 'extend', 'index', 'insert', 'pop', 'remove',
   'reverse', 'sort']

>1) is there a way to get cPickle to accept the buffer item returned 
>out of the dataset via the recordset emulation offered in win32com?

Yeah, turn it into a string.  ;-)

>2) is there a good discussion of saving non-text items into databases 
>(access or some other database) via pickling/unpickling python 
>objects/data?  I know that Zope does this into their own database, 
>but I need a more conventional relational database.  

Your problem seems to be just one of getting Access to hand you back the
original string you handed it.  I have no idea about that, but it shouldn't
be TOO hard...

Sean
-- 
 Tools may limit the user, but the utility of tools is limited by the
 skill of the user.  -- Leonard Compagno
Sean Reifschneider, Inimitably Superfluous <jafo at tummy.com>
tummy.com - Linux Consulting since 1995. Qmail, KRUD, Firewalls, Python



More information about the FRPythoneers mailing list