[melbourne-pug] Inserting images into MSSQL using Python

David Crisp dcrisp at netspace.net.au
Mon Jan 20 06:44:00 CET 2014


Dave,  Pil was just an example of the tools i had been playing with at the 
time I was trying to work out the DB insertts.


On Mon, 20 Jan 2014, Dave Collins wrote:

> David,
> What data type are using using in the database?
>
> You should not need PIL to read or write data in from disk and put into
> a database.
>
> dave
>
>
> On Mon, 2014-01-20 at 15:47 +1100, David Crisp wrote:
>> Using Python, What is the best method for reading a small PNG file from
>> disk then writing it to a MS SQL database (2008)   and then retrieiving
>> the binary data and writing it out to disk as a valid png file.
>>
>> THis is for writing VERY small (700 byte) monocrhome PNG file to the
>> database.
>>
>> The prefered Python MSSQL engine Im using is PYMSSQL.   its the one I have
>> used for the rest of the text so its the one I need to use for the binary
>> data.
>>
>> I have fiddled with the PIL / PILLOW library
>>
>> I think my problem is im looking in the wrong directions!
>>
>> How do other people do this?
>> Regards,
>> David
>>
>> _______________________________________________
>> melbourne-pug mailing list
>> melbourne-pug at python.org
>> https://mail.python.org/mailman/listinfo/melbourne-pug
>
>
> _______________________________________________
> melbourne-pug mailing list
> melbourne-pug at python.org
> https://mail.python.org/mailman/listinfo/melbourne-pug
>


More information about the melbourne-pug mailing list