Re: percentile value check can be slow

2017-11-18 Thread David Fetter
On Sat, Nov 18, 2017 at 11:05:47PM +0100, Tomas Vondra wrote: > Hi, > > On 11/18/2017 10:30 PM, David Fetter wrote: > > On Sat, Nov 18, 2017 at 10:44:36AM -0500, Tom Lane wrote: > >> jotpe writes: > >>> I tried to enter invalid percentile fractions, and was astonished > >>> that

Re: [HACKERS] pg_basebackup --progress output for batch execution

2017-11-18 Thread Tomas Vondra
On 11/10/2017 02:32 PM, Martín Marqués wrote: > Hi, > > Thanks for having a look at this patch. > > 2017-11-09 20:55 GMT-03:00 Jeff Janes : >> On Fri, Sep 29, 2017 at 4:00 PM, Martin Marques >> wrote: >>> >>> Hi, >>> >>> Some time ago I

Re: [HACKERS] new function for tsquery creartion

2017-11-18 Thread Tomas Vondra
Hi, On 09/13/2017 10:57 AM, Victor Drobny wrote: > On 2017-09-09 06:03, Thomas Munro wrote: >> Please send a rebased version of the patch for people to review and >> test as that one has bit-rotted. > Hello, > Thank you for interest. In the attachment you can find rebased > version(based on

Re: Logical Replication and triggers

2017-11-18 Thread Craig Ringer
On 15 November 2017 at 21:12, Thomas Rosenstein < thomas.rosenst...@creamfinance.com> wrote: > I would like somebody to consider Petr Jelineks patch for worker.c from > here (https://www.postgresql.org/message-id/619c557d-93e6-1833-16 > 92-b010b176ff77%402ndquadrant.com) > > I'm was facing the

Re: [JDBC] [HACKERS] Channel binding support for SCRAM-SHA-256

2017-11-18 Thread Michael Paquier
On Sun, Nov 19, 2017 at 12:56 AM, Peter Eisentraut wrote: > On 11/18/17 06:32, Michael Paquier wrote: >> + cbind_header_len = 4 + strlen(state->channel_binding_type); /* >> p=type,, */ >> + cbind_input_len = cbind_header_len + cbind_data_len; >> +

Re: [HACKERS] ginInsertCleanup called from vacuum could still miss tuples to be deleted

2017-11-18 Thread Peter Geoghegan
On Thu, Nov 16, 2017 at 2:16 PM, Jeff Janes wrote: > e2c79e14 was to fix a pre-existing bug, but probably e9568083 made that bug > easier to hit than it was before. (Which is not to say that e9568083 can't > contain bugs of its own, of course) I get that. I think that the

Re: [HACKERS] Bug in to_timestamp().

2017-11-18 Thread Tom Lane
Artur Zakirov writes: > [ 0001-to-timestamp-format-checking-v7.patch ] This patch needs a rebase over the formatting.c fixes that have gone in over the last couple of days. Looking at the rejects, I notice that in your changes to parse_format(), you seem to be making

Re: spgist rangetypes compiler warning (gcc 7.2.0)

2017-11-18 Thread Tomas Vondra
On 11/18/2017 10:40 PM, Tom Lane wrote: > Tomas Vondra writes: >> while compiling on gcc 7.2.0 (on ARM), I got this warning: > >> rangetypes_spgist.c: In function 'spg_range_quad_inner_consistent': >> rangetypes_spgist.c:559:29: warning: comparison between

Re: percentile value check can be slow

2017-11-18 Thread Tomas Vondra
Hi, On 11/18/2017 10:30 PM, David Fetter wrote: > On Sat, Nov 18, 2017 at 10:44:36AM -0500, Tom Lane wrote: >> jotpe writes: >>> I tried to enter invalid percentile fractions, and was astonished >>> that it seems to be checked after many work is done? >> >> IIRC, only the

Re: [HACKERS] VACUUM and ANALYZE disagreeing on what reltuples means

2017-11-18 Thread Tom Lane
Tomas Vondra writes: > On 11/02/2017 08:15 PM, Tom Lane wrote: >> However, I'm not sure we're there yet, because there remains a fairly >> nasty discrepancy even once we've gotten everyone onto the same page >> about reltuples counting just live tuples: VACUUM and

Re: [HACKERS] VACUUM and ANALYZE disagreeing on what reltuples means

2017-11-18 Thread Tomas Vondra
Hi, On 11/02/2017 08:15 PM, Tom Lane wrote: > Haribabu Kommi writes: >> The changes are fine and now it reports proper live tuples in both >> pg_class and stats. The other issue of continuous vacuum operation >> leading to decrease of number of live tuples is not

Re: spgist rangetypes compiler warning (gcc 7.2.0)

2017-11-18 Thread Tom Lane
Tomas Vondra writes: > while compiling on gcc 7.2.0 (on ARM), I got this warning: > rangetypes_spgist.c: In function 'spg_range_quad_inner_consistent': > rangetypes_spgist.c:559:29: warning: comparison between pointer and > zero character constant

Re: [HACKERS] Repetitive code in RI triggers

2017-11-18 Thread Tom Lane
Ildar Musin writes: > [ ri_triggers_v2.patch ] Pushed with two minor improvements. I noticed that ri_setdefault could just go directly to ri_restrict rather than call the two separate triggers that would end up there anyway; that lets its argument be "TriggerData

Re: WIP: BRIN multi-range indexes

2017-11-18 Thread Tomas Vondra
Hi, Apparently there was some minor breakage due to duplicate OIDs, so here is the patch series updated to current master. regards -- Tomas Vondra http://www.2ndQuadrant.com PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

Re: [HACKERS] PATCH: multivariate histograms and MCV lists

2017-11-18 Thread Tomas Vondra
Hi, Attached is an updated version of the patch, adopting the psql describe changes introduced by 471d55859c11b. regards -- Tomas Vondra http://www.2ndQuadrant.com PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services 0001-multivariate-MCV-lists.patch.gz

Re: [HACKERS] Consistently catch errors from Python _New() functions

2017-11-18 Thread Tom Lane
Peter Eisentraut writes: > On 11/17/17 12:16, Tom Lane wrote: >> I'm confused by the places that change PLy_elog calls to pass NULL: >> >> -PLy_elog(ERROR, "could not create globals"); >> +PLy_elog(ERROR, NULL); >> >> How is that an

Re: to_typemod(type_name) information function

2017-11-18 Thread Sophie Herold
On 18/11/17 16:50, Tom Lane wrote: > Sophie Herold writes: >> I need to test a (user) given column type name, with one in the database >> for equality. To this end, I have to do some kind of normalization (e.g. >> 'timestamptz(2)' to 'timestamp (2) with time zone'.) > >

Re: [HACKERS] Consistently catch errors from Python _New() functions

2017-11-18 Thread Peter Eisentraut
On 11/17/17 12:16, Tom Lane wrote: > I'm confused by the places that change PLy_elog calls to pass NULL: > > - PLy_elog(ERROR, "could not create globals"); > + PLy_elog(ERROR, NULL); > > How is that an improvement? Otherwise it looks reasonable. If we pass NULL, then

Re: [JDBC] [HACKERS] Channel binding support for SCRAM-SHA-256

2017-11-18 Thread Peter Eisentraut
On 11/18/17 06:32, Michael Paquier wrote: > Here are some comments. > > +* The client requires channel biding. Channel binding type > s/biding/binding/. fixed > if (!state->ssl_in_use) > + /* > +* Without SSL, we don't support

Re: [JDBC] [HACKERS] Channel binding support for SCRAM-SHA-256

2017-11-18 Thread Michael Paquier
On Sat, Nov 18, 2017 at 4:31 AM, Peter Eisentraut wrote: > I made some significant changes to the logic. Thanks! > The selection of the channel binding flag (n/y/p) in the client seemed > wrong. Your code treated 'y' as an error, but I think that is a >

percentile value check can be slow

2017-11-18 Thread jotpe
I tried to enter invalid percentile fractions, and was astonished that it seems to be checked after many work is done? psql (11devel) Type "help" for help. jotpe=# \timing Timing is on. jotpe=# select percentile_cont(array[0,0.25,0.5,1,1,null,2]) within group(order by txk) from klima_tag;