How to store an image in postgresQL

Creating desktop or client-server database solutions?

Moderators: Klaus, FourthWorld, heatherlaine, kevinmiller, robinmiller

Post Reply
UKMC
Posts: 50
Joined: Sun Jan 08, 2017 12:01 pm

How to store an image in postgresQL

Post by UKMC » Wed Feb 15, 2017 10:08 pm

Hi altogether,

I have a binary picture into a LC-variable and want to store it in a postgresQL bytea-column.
How should the insert statement look like to make it work ?
All I've found in the net did not work at all

I hope, there is one out there who can help

Best regards in advance

Ulrich

UKMC
Posts: 50
Joined: Sun Jan 08, 2017 12:01 pm

Re: How to store an image in postgresQL

Post by UKMC » Wed Feb 15, 2017 10:53 pm

Dear colleagues,

I just found the solution, it's using base64encode() and base64decode()

It works perfect

Best regards


Ulrich

Post Reply

Return to “Databases”