in reply to Inserting picture into blob
You're mixing up placeholders/quoting. If you are using placeholders in your query, do not quote the values, the placeholder takes care of that.
Note, this probably isn't why it's failing, but it will (probably) give you a broken image if you quote, and use placeholders.
Update: added second comment