[SOLVED] Convert picture bytea to binary in a python file
I would like to know if it possible to concert bytea picture into binary. I take the bytea into a field of the database and i want to "put" it into a binary field like this:
cr.execute('SELECT res_company.logo_web FROM res_company') res = cr.fetchall() v['logo_Print'] =base64.decodestring(str(res))
But doesn't work.
Someone have some idea, please? How is possible to concert my "tuple" into a string and after binary?
Thanks a lot!