Re: ERROR: cannot start subtransactions during a parallel operation

2018-07-01 Thread Mai Peng
Hello, how could I relax the subtransaction restriction, I used the Parallel Unsafe option, but still have the same issue. Rgds. Le ven. 29 juin 2018 20:47, Andres Freund a écrit : > Hi, > > On 2018-06-29 20:37:23 +0200, Tomas Vondra wrote: > > My guess is that it's a PL/pgSQL function with an E

Commitfest 2018-07 is underway

2018-07-01 Thread Andrew Dunstan
Hi Commitfest 2018-07, the first of the release 12 development cycle, is underway. New patches will need to be submitted to the next commitfest, 2018-09. Patch authors are reminded of the very useful patch tester too at . You should check regularly if your

Re: Subplan result caching

2018-07-01 Thread Peter Eisentraut
On 23.05.18 11:31, Heikki Linnakangas wrote: > I've been working on a patch to add a little cache to SubPlans, to speed > up queries with correlated subqueries, where the same subquery is > currently executed multiple times with the same parameters. The idea is > to cache the result of the subpl

Re: location reporting in TAP test failures

2018-07-01 Thread Peter Eisentraut
On 21.06.18 19:30, Heikki Linnakangas wrote: > Looks good. I wish there was some way to remind to do this for any > future test helper functions, too, but I don't have any ideas off the > top of my head. Committed. > Since this is purely a test change, IMO this could go to master now, no > nee

Re: Adding tests for inheritance trees with temporary tables

2018-07-01 Thread Michael Paquier
On Thu, Jun 21, 2018 at 02:37:46PM +0900, Michael Paquier wrote: > On Wed, Jun 20, 2018 at 06:34:42PM +0530, Ashutosh Bapat wrote: > > Thanks. I have checked that make check passes with this patch. I have > > marked this entry as ready for committer. > > Thanks, Ashutosh. Now pushed. Thanks Ashu

Re: location reporting in TAP test failures

2018-07-01 Thread Michael Paquier
On Sun, Jul 01, 2018 at 01:17:07PM +0200, Peter Eisentraut wrote: > On 21.06.18 19:30, Heikki Linnakangas wrote: >> Since this is purely a test change, IMO this could go to master now, no >> need to wait for until v12 development starts. > > I didn't want to deal with the potential for some versi

Re: Push down Aggregates below joins

2018-07-01 Thread Peter Eisentraut
On 20.06.18 22:12, Heikki Linnakangas wrote: > Currently, the planner always first decides the scan/join order, and > adds Group/Agg nodes on top of the joins. Sometimes it would be legal, > and beneficial, to perform the aggregation below a join. I've been > hacking on a patch to allow that. B

Re: PATCH: logical_work_mem and logical streaming of large in-progress transactions

2018-07-01 Thread Peter Eisentraut
This patch set was not updated for the 2018-07 commitfest, so moved to -09. On 09.03.18 17:07, Peter Eisentraut wrote: > I think this patch is not going to be ready for PG11. > > - It depends on some work in the thread "logical decoding of two-phase > transactions", which is still in progress. >

Re: libpq example doesn't work

2018-07-01 Thread Peter Eisentraut
On 27.06.18 08:29, Ideriha, Takeshi wrote: > When I tried to use libpq, I found that libpq example[1] does not work. > That's because SELECT pg_catlog.set_config() never returns PGRES_COMMAND_OK > which is expected, > but actually returns PGRES_TUPLES_OK. Fixed. There were additional similar cas

Re: patch to allow disable of WAL recycling

2018-07-01 Thread Peter Eisentraut
On 26.06.18 15:35, Jerry Jelinek wrote: > Attached is a patch to provide an option to disable WAL recycling. We > have found that this can help performance by eliminating > read-modify-write behavior on old WAL files that are no longer resident > in the filesystem cache. The is a lot more detail on

Re: Small fixes about backup history file in doc and pg_standby

2018-07-01 Thread Peter Eisentraut
On 27.06.18 18:22, Yugo Nagata wrote: > On Wed, 27 Jun 2018 18:36:46 +0900 > Michael Paquier wrote: > >> On Wed, Jun 27, 2018 at 05:42:07PM +0900, Yugo Nagata wrote: >>> On Wed, 27 Jun 2018 00:58:18 +0900 >>> Fujii Masao wrote: > In addition, the current pg_standby still can handle a backup

branches_of_interest.txt

2018-07-01 Thread Andrew Dunstan
This file on the buildfarm server is used to tell clients which branches we'd like built. When a new stable branch is created it's added manually to this file, and when one gets to EOL it's removed from the file. This is a rather cumbersome process, and it occurred to me that it could be str

Re: Cache lookup errors with functions manipulation object addresses

2018-07-01 Thread Michael Paquier
On Wed, May 16, 2018 at 01:03:18PM +0900, Michael Paquier wrote: > Okay, I have done so in the updated set attached. I have added some > documentation as well in fdwhandler.sgml about those two new things. > That's too late for v11 of course, so let's them sit until the time > comes. Attached are

Re: branches_of_interest.txt

2018-07-01 Thread Tom Lane
Andrew Dunstan writes: > This file on the buildfarm server is used to tell clients which branches > we'd like built. When a new stable branch is created it's added manually > to this file, and when one gets to EOL it's removed from the file. This > is a rather cumbersome process, and it occurre

Re: Cache lookup errors with functions manipulation object addresses

2018-07-01 Thread Andrew Dunstan
On 07/01/2018 10:27 AM, Michael Paquier wrote: On Wed, May 16, 2018 at 01:03:18PM +0900, Michael Paquier wrote: Okay, I have done so in the updated set attached. I have added some documentation as well in fdwhandler.sgml about those two new things. That's too late for v11 of course, so let's

Should contrib modules install .h files?

2018-07-01 Thread Andrew Gierth
So I have this immediate problem: a PGXS build of a module, specifically an hstore transform for a non-core PL, is much harder than it should be because it has no way to get at hstore.h since that file is never installed anywhere. Should that be changed? -- Andrew (irc:RhodiumToad)

Re: Should contrib modules install .h files?

2018-07-01 Thread Andres Freund
Hi, On 2018-07-01 19:23:03 +0100, Andrew Gierth wrote: > So I have this immediate problem: a PGXS build of a module, specifically > an hstore transform for a non-core PL, is much harder than it should be > because it has no way to get at hstore.h since that file is never > installed anywhere. > >

Large Commitfest items

2018-07-01 Thread Andrew Dunstan
There has been some discussion around excluding large items from the current commitfest, for several reasons. However I don't recall ever seeing a definition of a large item. It seems to be a bit like "I know it when I see it." I've been looking at the current commitfest entries. Based on that I

Re: Large Commitfest items

2018-07-01 Thread Andres Freund
Hi, On 2018-07-01 14:46:47 -0400, Andrew Dunstan wrote: > There has been some discussion around excluding large items from the > current commitfest, for several reasons. However I don't recall ever > seeing a definition of a large item. It seems to be a bit like "I know > it when I see it." I've

Re: Postgres 11 release notes

2018-07-01 Thread Jonathan S. Katz
> On Jun 30, 2018, at 5:52 PM, Tom Lane wrote: > > Yaroslav writes: >> I've noticed the following in v11 release notes: >> "Window functions now support all options shown in the SQL:2011 standard, >> including RANGE distance PRECEDING/FOLLOWING, GROUPS mode, and frame >> exclusion options" > >

Re: [HACKERS] Removing [Merge]Append nodes which contain a single subpath

2018-07-01 Thread David Rowley
Now that the September 'fest is open for new patches I'm going to move this patch over there. This patch has become slightly less important than some other stuff, but I'd still like to come back to it. -- David Rowley http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 S

Re: Commitfest 2018-07 is underway

2018-07-01 Thread Tatsuo Ishii
> Patch authors are reminded of the very useful patch tester too at > . You should check regularly if your > patch is still applying, building, and testing nicely. There are > currently quite a significant number of patches listed which don't > apply or don't build/t

Re: Commitfest 2018-07 is underway

2018-07-01 Thread Andrew Dunstan
On Sun, Jul 1, 2018 at 7:02 PM, Tatsuo Ishii wrote: >> Patch authors are reminded of the very useful patch tester too at >> . You should check regularly if your >> patch is still applying, building, and testing nicely. There are >> currently quite a significant numb

Re: Commitfest 2018-07 is underway

2018-07-01 Thread Thomas Munro
On Mon, Jul 2, 2018 at 11:24 AM, Andrew Dunstan wrote: > On Sun, Jul 1, 2018 at 7:02 PM, Tatsuo Ishii wrote: >>> Patch authors are reminded of the very useful patch tester too at >>> . You should check regularly if your >>> patch is still applying, building, and te

RE: Bulk Insert into PostgreSQL

2018-07-01 Thread Tsunakawa, Takayuki
From: Srinivas Karthik V [mailto:skarthikv.i...@gmail.com] > I was using copy command to load. Removing the primary key constraint on > the table and then loading it helps a lot. In fact, a 400GB table was loaded > and the primary constraint was added in around 15 hours. Thanks for the > wonderful

Re: Synchronous replay take III

2018-07-01 Thread Thomas Munro
On Sat, Mar 3, 2018 at 2:11 AM, Adam Brusselback wrote: > Thanks Thomas, appreciate the rebase and the work you've done on this. > I should have some time to test this out over the weekend. Rebased. Moved to September. I still need to provide a TAP test and explain that weirdness reported by Dm

Re: Large Commitfest items

2018-07-01 Thread Craig Ringer
On 2 July 2018 at 02:50, Andres Freund wrote: > Hi, > > On 2018-07-01 14:46:47 -0400, Andrew Dunstan wrote: > > There has been some discussion around excluding large items from the > > current commitfest, for several reasons. However I don't recall ever > > seeing a definition of a large item. It

Re: Bulk Insert into PostgreSQL

2018-07-01 Thread Peter Geoghegan
On Sun, Jul 1, 2018 at 5:19 PM, Tsunakawa, Takayuki wrote: > 400 GB / 15 hours = 7.6 MB/s > > That looks too slow. I experienced a similar slowness. While our user tried > to INSERT (not COPY) a billion record, they reported INSERTs slowed down by > 10 times or so after inserting about 500 mil

Re: Commitfest 2018-07 is underway

2018-07-01 Thread Tatsuo Ishii
>>> Does this test doc building? >> >> Good question. Thomas? > > Yes. You can't see the resulting HTML or anything... but it does fail > if you break the documentation build. Great! Thanks for the explanation. Best regards, -- Tatsuo Ishii SRA OSS, Inc. Japan English: http://www.sraoss.co.jp/i

RE: Bulk Insert into PostgreSQL

2018-07-01 Thread Tsunakawa, Takayuki
From: Peter Geoghegan [mailto:p...@bowt.ie] > What kind of data was indexed? Was it a bigserial primary key, or > something else? Sorry, I don't remember it. But the table was for storing some machine usage data, and I don't think any sequence was used in the index. According to my faint memory

Re: Large Commitfest items

2018-07-01 Thread Andrew Dunstan
On Sun, Jul 1, 2018 at 9:36 PM, Craig Ringer wrote: > On 2 July 2018 at 02:50, Andres Freund wrote: >> >> Hi, >> >> On 2018-07-01 14:46:47 -0400, Andrew Dunstan wrote: >> > There has been some discussion around excluding large items from the >> > current commitfest, for several reasons. However I

mxid_age() and age(xid) appear undocumented

2018-07-01 Thread David Rowley
I see d692308cf494f6126 mentions mxid_age() in passing, but there appears to be no formal definition of either of these functions. Should there be? -- David Rowley http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training & Services

Re: Monitoring time of fsyncing WALs

2018-07-01 Thread Craig Ringer
On 1 July 2018 at 11:29, Michael Paquier wrote: > > So at the end, I would like to use the proposed patch and call it a > day. Thoughts? > > Patch looks good. I'll hijack the thread to add a few more perf/dtrace tracepoints in the WAL code, as they were also missing. Proposed rider patch attac

Re: Comment refers to non existent function IncreaseRestartDecodingForSlot

2018-07-01 Thread Michael Paquier
On Fri, Jun 29, 2018 at 05:34:21PM -0300, Euler Taveira wrote: > LogicalIncreaseXminForSlot (it is a few lines above). It has been like > that since logical decoding was introduced. The trivial patch fixes > it. That looks right to me. Pushed. -- Michael signature.asc Description: PGP signature

pg_stat_statements_reset() function execute permissions doc update

2018-07-01 Thread Haribabu Kommi
The pg_stat_statements_reset() function can be executed by super and members of the role pg_read_all_stats, but document doesn't say that. This is found during the code review of another patch in [1]. Patch attached. This needs a backpatch till 10 where the default roles are added. [1] - https://

Re: New function pg_stat_statements_reset_query() to reset statistics of a specific query

2018-07-01 Thread Haribabu Kommi
On Fri, Jun 29, 2018 at 6:14 PM Sergei Kornilov wrote: > Hello > Thank you for update > Thanks for the review. > It may be better to use NULL as the default value at sql level. > Changed. > > ereport(LOG, (errmsg("userid %u, dbid %u, queryid %ld does not exist", > userid, dbid, queryid)));

Re: Remove mention in docs that foreign keys on partitioned tables are not supported

2018-07-01 Thread Ashutosh Bapat
On Fri, Jun 29, 2018 at 6:35 PM, Tomas Vondra wrote: > > > On 06/29/2018 02:30 PM, Robert Haas wrote: >> >> On Wed, Jun 27, 2018 at 10:26 PM, Amit Langote >> wrote: >>> >>> By the way, picking up on the word "inherited" in the error message shown >>> above, I wonder if you decided against using s

Re: Remove mention in docs that foreign keys on partitioned tables are not supported

2018-07-01 Thread Amit Langote
On 2018/07/02 14:46, Ashutosh Bapat wrote: > This constraint was added to the partitioned table and inherited from > there. If user wants to drop that constraint for some reason, this > error message doesn't help. The error message tells why he can't drop > it, but doesn't tell, directly or indirec

Re: [HACKERS] SERIALIZABLE with parallel query

2018-07-01 Thread Masahiko Sawada
On Fri, Jun 29, 2018 at 7:28 PM, Thomas Munro wrote: > On Thu, Jun 28, 2018 at 7:55 PM, Masahiko Sawada > wrote: >> I'd like to test and review this patches but they seem to conflict >> with current HEAD. Could you please rebase them? > > Hi Sawada-san, > > Thanks! Rebased and attached. The on

Re: inconsistency and inefficiency in setup_conversion()

2018-07-01 Thread John Naylor
I've attached v4, which is a rebase plus some comment revisions. -John Naylor From 4d1cb1d40c5c79c732e5433e95f8560fb41e20bd Mon Sep 17 00:00:00 2001 From: John Naylor Date: Mon, 2 Jul 2018 12:52:07 +0700 Subject: [PATCH v4 1/2] Add pg_language lookup. This didn't seem worth doing before, but an