Asymmetric partition-wise JOIN

2019-08-11 Thread Kohei KaiGai
Hello, PostgreSQL optimizer right now considers join pairs on only non-partition - non-partition or partition-leaf - partition-leaf relations. On the other hands, it is harmless and makes sense to consider a join pair on non-partition - partition-leaf. See the example below. ptable is partitioned

Re: How to retain lesser paths at add_path()?

2019-08-11 Thread Kohei KaiGai
Hello, For implementation of the concept, this patch puts a hook on add_path / add_partial_path to override the path removal decision by extensions, according to its own viewpoint. We don't add any metrics other than path's cost and path keys, so set_cheapest() still picks up paths based on its co

Re: SegFault on 9.6.14

2019-08-11 Thread Thomas Munro
On Sat, Aug 10, 2019 at 12:59 AM Robert Haas wrote: > But beyond that, the issue here is that the Limit node is shutting > down the Gather node too early, and the right fix must be to stop > doing that, not to change the definition of what it means to shut down > a node, as this patch does. So ma

Re: Parallel Append subplan order instability on aye-aye

2019-08-11 Thread Tom Lane
Thomas Munro writes: > On Wed, Jul 24, 2019 at 11:59 AM Thomas Munro wrote: >> On Tue, Jul 16, 2019 at 12:21 PM Tom Lane wrote: >>> In the meantime, we've had *lots* of buildfarm failures in the >>> added pg_stat_all_tables query, which indicate that indeed the >>> stats collector mechanism isn'

Re: [GSoC] artbufmgr

2019-08-11 Thread pantilimonov michael
Hello everyone, > It should be noted that such workload does not really represents 'real life' > results, > as all contention goes into certain partitions (in case of hashtable) and > subtrees (in case of tree). > Next goal is to compare data structures on some kind of realistic benchmark > or

Re: Table inheritance and column ordering question

2019-08-11 Thread Tom Lane
Stephan Doliov writes: > I'd like to know whether there is any way to control the order of inherited > columns? Nope, not at present. There's a lot of wished-for functionality around separating the presentation order of table columns from their physical storage order. If we had that it'd fix you

Re: SQL/JSON path: collation for comparisons, minor typos in docs

2019-08-11 Thread Alexander Korotkov
On Fri, Aug 9, 2019 at 5:27 PM Alexander Korotkov wrote: > On Thu, Aug 8, 2019 at 11:30 PM Alexander Korotkov > wrote: > > On Thu, Aug 8, 2019 at 11:53 AM Markus Winand > > wrote: > > > The patch makes my tests pass. > > > > Cool. > > > > > I wonder about a few things: > > > > > > - Isn’t there

Re: Regression test failure in regression test temp.sql

2019-08-11 Thread Tom Lane
Michael Paquier writes: > On Wed, Aug 07, 2019 at 10:17:25AM -0400, Tom Lane wrote: >> Not objecting to the patch, exactly, just feeling like there's >> more here than meets the eye. Not quite sure if it's worth >> investigating closer, or what we'd even need to do to do so. > Yes, something's w

Re: Add "password_protocol" connection parameter to libpq

2019-08-11 Thread Peter Eisentraut
On 2019-08-11 21:46, Jonathan S. Katz wrote: > On 8/11/19 1:00 PM, Peter Eisentraut wrote: >> On 2019-08-09 23:56, Jeff Davis wrote: >>> 1. Hierarchical semantics, where you specify the least-secure >>> acceptable method: >>> >>> password_protocol = {any,md5,scram-sha-256,scram-sha-256-plus} >> >

Re: Add "password_protocol" connection parameter to libpq

2019-08-11 Thread Jonathan S. Katz
On 8/11/19 1:00 PM, Peter Eisentraut wrote: > On 2019-08-09 23:56, Jeff Davis wrote: >> 1. Hierarchical semantics, where you specify the least-secure >> acceptable method: >> >> password_protocol = {any,md5,scram-sha-256,scram-sha-256-plus} > > What would the hierarchy be if scram-sha-512 and sc

Table inheritance and column ordering question

2019-08-11 Thread Stephan Doliov
Hi all, I hope this is the right list for my question, if not, please let me know to which list I should send the question. I'd like to know whether there is any way to control the order of inherited columns? This is purely an issue of syntactic sugar for me. I'd like to be able to do the followi

Re: Undocumented PQdisplayTuples and PQprintTuples in libpq

2019-08-11 Thread Tom Lane
Michael Paquier writes: > On Mon, Aug 05, 2019 at 06:54:32AM +0200, Fabien COELHO wrote: >> How do you know that they are not used by anyone in the wild? >> If they are broken, it would be a clue. If not, possibly someone somewhere >> could be using it, eg for debug (what does this result look lik

Re: Add "password_protocol" connection parameter to libpq

2019-08-11 Thread Peter Eisentraut
On 2019-08-09 23:56, Jeff Davis wrote: > 1. Hierarchical semantics, where you specify the least-secure > acceptable method: > > password_protocol = {any,md5,scram-sha-256,scram-sha-256-plus} What would the hierarchy be if scram-sha-512 and scram-sha-512-plus are added? -- Peter Eisentraut

Feature Request: insert/on conflict update status

2019-08-11 Thread Roby
Hi all, Following a recent bug report () it was suggested that that I submit a feature request for the ability to test whether an (insert / on conflict update) "upsert" resulted in an insert or an updat

Re: Fix typos and inconsistencies for HEAD (take 10)

2019-08-11 Thread Alexander Lakhin
Hello hackers, Please consider fixing the next heap of typos and inconsistencies in the tree: 10.1. query_txt -> query text 10.2. quote_object_names -> quote_object_name 10.3. ragetypes_typanalyze.c -> rangetypes_typanalyze.c 10.4. RAISE_EXCEPTION -> ERRCODE_RAISE_EXCEPTION 10.5. rb_lower -> remo

Re: Global temporary tables

2019-08-11 Thread Pavel Stehule
Hi > There is one more problem with global temporary tables for which I do not > know good solution now: collecting statistic. > As far as each backend has its own data, generally them may need different > query plans. > Right now if you perform "analyze table" in one backend, then it will > affe