From: | Andreas Joseph Krogh <andreas(at)visena(dot)com> |
---|---|
To: | "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com> |
Cc: | "pgsql-sql(at)lists(dot)postgresql(dot)org" <pgsql-sql(at)lists(dot)postgresql(dot)org> |
Subject: | Re: ORDER BY elements in ARRAY |
Date: | 2024-08-27 16:27:26 |
Message-ID: | VisenaEmail.23.cb59002578ada57.19194a9213f@origo-test01.app.internal.visena.net |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
På tirsdag 27. august 2024 kl. 18:03:37, skrev David G. Johnston <
david(dot)g(dot)johnston(at)gmail(dot)com <mailto:david(dot)g(dot)johnston(at)gmail(dot)com>>:
On Tuesday, August 27, 2024, Andreas Joseph Krogh <andreas(at)visena(dot)com
<mailto:andreas(at)visena(dot)com>> wrote:
[…]
This doesn't really do it. I'm looking for something analogous to Java's
Comparator-interface so the custom datatype knows how to sort itself.
Ah. Then either just put those two values into the first two field positions
of your custom type and live with an easy, but also self-contained, hack, or
figure out what incantations of create operator and/or create operator family
are need to install custom behavior for the b-tree < and > operators. I’m 80%
sure it’s doable, 60% in plpgsql…
David J.
Ah, seems CREATE OPERATOR is worth pursuing.
Thanks.
--
Andreas Joseph Krogh
CTO / Partner - Visena AS
Mobile: +47 909 56 963
andreas(at)visena(dot)com <mailto:andreas(at)visena(dot)com>
www.visena.com <https://www.visena.com>
<https://www.visena.com>
From | Date | Subject | |
---|---|---|---|
Next Message | Frank Komsic | 2024-09-03 22:14:40 | Re: Powerfailure caused a reduction in INSERT performance of version 12 database. |
Previous Message | David G. Johnston | 2024-08-27 16:17:29 | object mapping for json/jsonb columns |