Re: BUG #14064: Sort order of bytea, etc. not defined

From: Chris Pacejo <cpacejo(at)clearskydata(dot)com>
To: Pavel Golub <pavel(at)gf(dot)microolap(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #14064: Sort order of bytea, etc. not defined
Date: 2016-05-04 12:09:34
Message-ID: CAC8iE5jkUyo-Kmzh-FzLQzpe6TOLnhSgJbJw8FmHto5GbK=PbQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

I'm not sure I understand? I know the data is bytea, how would casting it
to another type help? (I don't think casting bytea is even possible?)
On May 4, 2016 2:16 AM, "Pavel Golub" <pavel(at)microolap(dot)com> wrote:

> Hello, Cpacejo.
>
> You wrote:
>
> ccc> The following bug has been logged on the website:
>
> ccc> Bug reference: 14064
> ccc> Logged by: Chris Pacejo
> ccc> Email address: cpacejo(at)clearskydata(dot)com
> ccc> PostgreSQL version: 9.5.2
> ccc> Operating system: any
> ccc> Description:
>
> ccc> The documentation does not define (nor call out as undefined) the
> sort order
> ccc> of bytea, bit varying, and other sequence types. While the bytea
> sort order
> ccc> is unsurprising (a < b if a is a prefix of b, but b > a if a prefix
> of b >
> ccc> the same length prefix of a), it is not the only such "unsurprising"
> sort
> ccc> order, and it would be helpful to have the guarantee that this sort
> order
> ccc> can be relied upon (especially in concert with range types).
>
>
>
> You shouls use explicit type casting for such types.
>
> --
> With best wishes,
> Pavel mailto:pavel(at)gf(dot)microolap(dot)com
>
>

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2016-05-04 14:55:42 Re: [BUGS] Breakage with VACUUM ANALYSE + partitions
Previous Message Michael Paquier 2016-05-04 11:43:11 Re: BUG #14125: when master set tablespace,slave recovery xlog pending