Re: Can we get sha* function over text, that could be used in index?

From: Peter Eisentraut <peter(at)eisentraut(dot)org>
To: depesz(at)depesz(dot)com, pgsql-general mailing list <pgsql-general(at)postgresql(dot)org>
Subject: Re: Can we get sha* function over text, that could be used in index?
Date: 2026-02-19 14:48:33
Message-ID: 3dbae091-6168-4b4b-91dc-4bf1a3a51136@eisentraut.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 18.02.26 15:58, hubert depesz lubaczewski wrote:
> And while I kinda undestand, create-conversion, server-encoding, I don't
> really*grok* why we can't have immutable conversion to bytea. And/or
> versions of sha* functions that simply work on text.

Hash functions fundamentally work on a sequence of bytes, so bytea is
the right type. The encoding of text into bytes is complicated, so it
seems better if you handle that yourself depending on the local
requirements.

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Koen De Groote 2026-02-19 19:30:03 Re: Postgres restore sometimes restores to a point 2 days in the past
Previous Message Michael Paquier 2026-02-19 04:11:43 Re: Bug: PG 14 recovery failure