[SQLObject] How to show a bitmap from SQL?
SQLObject is a Python ORM.
Brought to you by:
ianbicking,
phd
|
From: S.Holmgren <ste...@ms...> - 2003-11-14 23:40:44
|
Hi, I'm new to SQL. picture loaded in a BLOB record...
Trying to do something like this:
mydb = MySQLdb.Connect(db='test')
cursor = mydb.cursor()
stmt = "select Picture, Nickname from Friends where Id=1"
cursor.execute(stmt)
resultSet = cursor.fetchall()
for p, n in resultSet:
pic = wxImage(p[0],wxBITMAP_TYPE_BMP)
self.pic1.SetBitmap(pic)
......
......
......
mydb.close()
Error: Can't load image from file:ÿ......
/Holmis
|