/ Published in: Python
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
# final solution for pymssql guid col value import uuid # ... x = uuid.UUID( bytes=rs[0][1] ) print x >>> print x >>> 524b585b-c827-db44-9d14-2dd72b6190fc # using pywintypes import pywintypes uv =pywintypes.IID( rs[0][1], True ) also from test code in my Python25 install s = "{00020400-0000-0000-C000-000000000046}" iid = pywintypes.IID(s) iid2 = pywintypes.IID(buffer(iid), True)