Re: Default ordering option

From: Cyril Champier <cyril(dot)champier(at)doctolib(dot)com>
To: Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Default ordering option
Date: 2019-07-25 11:12:09
Message-ID: CAJaA8Vf1t5b7RCf5y=cNQa-otundkXfsiXaN8vpZeVT-A+eRZw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Peter:
So I would need to create a pg extension encapsulating this hook callback?
If this is the case, it seems it will be much more complicated than
expected, and I wont be able to do it :(
But thanks for the suggestion anyway.

On Thu, Jul 25, 2019 at 12:21 PM Peter Eisentraut <
peter(dot)eisentraut(at)2ndquadrant(dot)com> wrote:

> On 2019-07-25 09:43, Cyril Champier wrote:
> > It might be an interesting exercise to implement this as a
> post-parsing
> > hook.
> >
> >
> > I known nothing about that, but that sounds interesting, do you have any
> > documentation pointer to help me implement that?
>
> Look for post_parse_analyze_hook. Walk the parsed query tree, look for
> queries without ordering clause and manufacture one.
>
> --
> Peter Eisentraut http://www.2ndQuadrant.com/
> PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
>

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Adrian Klaver 2019-07-25 14:55:13 Re: Default ordering option
Previous Message Peter Eisentraut 2019-07-25 10:21:54 Re: Default ordering option