Re: Images storing techniques

From: Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com>
To: Riccardo Gobbo <riccardo(dot)gobbo(dot)2(at)studenti(dot)unipd(dot)it>, pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: Images storing techniques
Date: 2023-03-30 13:41:42
Message-ID: 8d61f98e-b271-b817-db22-6875442e0def@enterprisedb.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 29.03.23 23:29, Riccardo Gobbo wrote:
> Question: for better performance is it better to store images as BYTEA
> or convert every image in base64 and store the generated string  (so in
> html it's enough to insert the base64 string in the tag)?
> Converting an image in base64 would use a 30% more memory than storing
> directly the image's bytes, but I don't know if working with characters
> rather than bytes could have more prons than cons

Storing as bytea is better.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2023-03-30 14:01:46 Re: Transparent column encryption
Previous Message Robert Haas 2023-03-30 13:41:39 Re: running logical replication as the subscription owner