Export my Mysql PDF binary_blob into a file
August 4, 2010 6:05 PM Subscribe
Exporting PDF binary blog data into an outfile with mysql. Yeah, remind me how to do that without getting corrupt files again?
posted by bhance to Computers & Internet (1 answer total)
I've got PDF data stored in a mysql database as a binary blob.
I just want to do a:
select binary_data into outfile "C:/exported.pdf" from file where id = 1234;
... but of course the resulting PDF file that I get is corrupted.
I know I've done this before - specifically with PDF data - and there was some magic trick with ESCAPED BY or characterset or some other magical $%^ing option that I can't remember now that my brain's fried.
What am I missing?