Convert binary string to something meaningful??

supercooper supercooper at gmail.com
Wed Jun 13 09:36:45 EDT 2007


I have this string that is being returned from a query on a DBISAM
database. The field must be some sort of blob, and when I connect to
the database thru ODBC in MS Access, the field type comes thru as OLE
Object, and Access cannot read the field (it usually crashes Access).
I can sorta pick out the data that I need (7.0, 28, 5TH PRINCIPAL MRD,
10.0 - and these occur in roughly the same place in every record
returned from the db), but I am wondering if there is a way to convert
this. I looked at the struct module, but I really dont know the format
of the data for sure. For starters, could someone tell me what '\x00'
more than likely is? Any hints on modules to look at or esp code
snippets would be greatly appreciated. Thanks.

\x9c
\x01\x00\x007.0\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00
28.0\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00
10.0\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\
x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00WN
\x00\x00\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00\x00\x10\xa3@
\x00\x00\x00\x00\x00\x10\x7f at NE NW SE
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00CONGRESS
QTR\x00\x00\x00\x005\x00\x005TH PRINCIPAL MRD
\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x0
0\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x0
0\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x0
0\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00




More information about the Python-list mailing list