Re: Introduce MIN/MAX aggregate functions to pg_lsn

2019-07-05 Thread Fabrízio de Royes Mello
On Fri, Jul 5, 2019 at 12:22 AM Michael Paquier wrote: > > On Thu, Jul 04, 2019 at 01:48:24PM -0300, Fabrízio de Royes Mello wrote: > > On Thu, Jul 4, 2019 at 10:57 AM Robert Haas wrote: > >> It would be pretty silly to have one and not the other, regardless of > >> whether we can think of an imm

Re: Introduce MIN/MAX aggregate functions to pg_lsn

2019-07-04 Thread Michael Paquier
On Thu, Jul 04, 2019 at 01:48:24PM -0300, Fabrízio de Royes Mello wrote: > On Thu, Jul 4, 2019 at 10:57 AM Robert Haas wrote: >> It would be pretty silly to have one and not the other, regardless of >> whether we can think of an immediate use case. > > +1 OK, applied with a catalog version bump.

Re: Introduce MIN/MAX aggregate functions to pg_lsn

2019-07-04 Thread Fabrízio de Royes Mello
On Thu, Jul 4, 2019 at 5:17 AM Michael Paquier wrote: > > On Tue, Jul 02, 2019 at 11:31:49AM -0300, Fabrízio de Royes Mello wrote: > > New version attached. > > This looks in pretty good shape to me, and no objections from me to > get those functions as the min() flavor is useful for monitoring WA

Re: Introduce MIN/MAX aggregate functions to pg_lsn

2019-07-04 Thread Fabrízio de Royes Mello
On Thu, Jul 4, 2019 at 10:57 AM Robert Haas wrote: > > On Thu, Jul 4, 2019 at 4:17 AM Michael Paquier wrote: > > Do you have a particular use-case in mind for max() one? I can think > > of at least one case: monitoring the flush LSNs of a set of standbys > > to find out how much has been replaye

Re: Introduce MIN/MAX aggregate functions to pg_lsn

2019-07-04 Thread Robert Haas
On Thu, Jul 4, 2019 at 4:17 AM Michael Paquier wrote: > Do you have a particular use-case in mind for max() one? I can think > of at least one case: monitoring the flush LSNs of a set of standbys > to find out how much has been replayed at most. It would be pretty silly to have one and not the o

Re: Introduce MIN/MAX aggregate functions to pg_lsn

2019-07-04 Thread Michael Paquier
On Tue, Jul 02, 2019 at 11:31:49AM -0300, Fabrízio de Royes Mello wrote: > New version attached. This looks in pretty good shape to me, and no objections from me to get those functions as the min() flavor is useful for monitoring WAL retention for complex deployments. Do you have a particular use

Re: Introduce MIN/MAX aggregate functions to pg_lsn

2019-07-02 Thread Fabrízio de Royes Mello
On Tue, Jul 2, 2019 at 7:22 AM Surafel Temesgen wrote: > > Hi, > Here are same review comment Thanks for your review. > - any numeric, string, date/time, network, or enum type, > + any numeric, string, date/time, network, lsn, or enum type, > or arrays of these types >

Re: Introduce MIN/MAX aggregate functions to pg_lsn

2019-07-02 Thread Surafel Temesgen
Hi, Here are same review comment - any numeric, string, date/time, network, or enum type, + any numeric, string, date/time, network, lsn, or enum type, or arrays of these types same as argument type In the documentation it refereed as pg_lsn type rather than lsn alone

Re: Introduce MIN/MAX aggregate functions to pg_lsn

2019-03-23 Thread Fabrízio de Royes Mello
On Fri, Mar 22, 2019 at 10:27 PM Michael Paquier wrote: > > On Fri, Mar 22, 2019 at 04:49:57PM -0300, Fabrízio de Royes Mello wrote: > > So attached patch aims to introduce MIN/MAX aggregate functions to pg_lsn > > Fine by me. This looks helpful for monitoring. > > Plea

Re: Introduce MIN/MAX aggregate functions to pg_lsn

2019-03-22 Thread Michael Paquier
On Fri, Mar 22, 2019 at 04:49:57PM -0300, Fabrízio de Royes Mello wrote: > So attached patch aims to introduce MIN/MAX aggregate functions to pg_lsn Fine by me. This looks helpful for monitoring. Please make sure to register it to the next commit fest: https://commitfest.postgresql.org/23/

Introduce MIN/MAX aggregate functions to pg_lsn

2019-03-22 Thread Fabrízio de Royes Mello
/MAX aggregate functions to pg_lsn datatype. Regards, -- Fabrízio de Royes Mello Timbira - http://www.timbira.com.br/ PostgreSQL: Consultoria, Desenvolvimento, Suporte 24x7 e Treinamento diff --git a/doc/src/sgml/func.sgml b/doc/src/sgml/func.sgml index 1a01473..490f3a8 100644 --- a