Re: [HACKERS] Explicit subtransactions for PL/Tcl

2017-03-08 Thread Victor Wagner
On Wed, 8 Mar 2017 16:49:33 +0100 Pavel Stehule wrote: > > I did a review of this patch > I'm attaching new version of patch with the issues pointed by you fixed. > > 4. A documentation is good - although I am not sure if it is well > structured - is level

Re: [HACKERS] foreign partition DDL regression tests

2017-03-08 Thread Ashutosh Bapat
> >> I didn't do anything about Ashutosh's comment that we could use ALTER >> FOREIGN TABLE rather than ALTER TABLE someplace; that didn't seem >> critical. > > Attached is a patch to fix that, just in case. Thanks. Looks good to me. -- Best Wishes, Ashutosh Bapat EnterpriseDB Corporation The

Re: [HACKERS] foreign partition DDL regression tests

2017-03-08 Thread Ashutosh Bapat
> >> At least we need to update the documentation. > > Got a proposal? How about something like attached? -- Best Wishes, Ashutosh Bapat EnterpriseDB Corporation The Postgres Database Company attach_part_constraint_doc.patch Description: Binary data -- Sent via pgsql-hackers mailing list

Re: [HACKERS] Reporting planning time with EXPLAIN

2017-03-08 Thread Ashutosh Bapat
On Thu, Mar 9, 2017 at 2:58 AM, Stephen Frost wrote: > Ashutosh, > > * Ashutosh Bapat (ashutosh.ba...@enterprisedb.com) wrote: >> On Tue, Mar 7, 2017 at 9:23 PM, Stephen Frost wrote: >> > I'm going through these with an eye towards committing them soon.

Re: [HACKERS] PATCH: psql show index with type info

2017-03-08 Thread Ashutosh Bapat
On Wed, Mar 8, 2017 at 7:00 PM, Stephen Frost wrote: > Ashutosh, > > * Ashutosh Bapat (ashutosh.ba...@enterprisedb.com) wrote: >> On Mon, Mar 6, 2017 at 7:54 PM, Amos Bird wrote: >> > Well, the prefix is used to differentiate other \d commands, like >> >

Re: [HACKERS] [BUG FIX] Removing NamedLWLockTrancheArray

2017-03-08 Thread Kyotaro HORIGUCHI
At Mon, 6 Mar 2017 19:32:25 +0530, Amit Kapila wrote in

Re: [HACKERS] wait events for disk I/O

2017-03-08 Thread Rushabh Lathia
Thanks Rajkumar for performing tests on this patch. Yes, I also noticed similar results in my testing. Additionally sometime I also noticed ReadSLRUPage event on my system. I also run the reindex database command and I notices below IO events. SyncImmedRelation, WriteDataBlock WriteBuffile,

Re: [HACKERS] Adding the optional clause 'AS' in CREATE TRIGGER

2017-03-08 Thread Tom Lane
"Okano, Naoki" writes: > Peter Eisentraut wrote: >>> I have a feeling that this was proposed a few times in the ancient past >>> but did not go through because of locking issues. I can't find any >>> emails about it through. Does anyone remember? Have you thought

Re: [HACKERS] Foreign Join pushdowns not working properly for outer joins

2017-03-08 Thread Ashutosh Bapat
>> >> Here's the patch attached. > > Agreed. It seems like a good idea to keep that logic in a single location Ok. > > I've beaten your patch around a bit and come up with the attached. The new name merge_fdw_options() is shorter than the one I chose, but we are not exactly merging options for

Re: [HACKERS] Gather Merge

2017-03-08 Thread Rushabh Lathia
On Thu, Mar 9, 2017 at 8:40 AM, Robert Haas wrote: > On Mon, Feb 20, 2017 at 1:35 AM, Rushabh Lathia > wrote: > > Thanks Amit for raising this point. I was not at all aware of > mark/restore. > > I tried to come up with the case, but haven't

Re: [HACKERS] Adding the optional clause 'AS' in CREATE TRIGGER

2017-03-08 Thread Okano, Naoki
Peter Eisentraut wrote: > On 3/8/17 04:12, Okano, Naoki wrote: > > Peter Eisentraut wrote: > >> I have a feeling that this was proposed a few times in the ancient past > >> but did not go through because of locking issues. I can't find any > >> emails about it through. Does anyone remember?

Re: [HACKERS] [PATCH] Off-by-one error in logical slot resource retention

2017-03-08 Thread Craig Ringer
On 9 March 2017 at 11:17, Craig Ringer wrote: > Hi all > > I've found a minor off-by-one error in the resource retention logic > for logical slots, where we treat confirmed_flush as meaning "flushed > up to and including this LSN". Seems reasonable, but the rest of the >

[HACKERS] [PATCH] Enabling atomics on ARM64

2017-03-08 Thread Roman Shaposhnik
Hi! I'd like to offer a forward port from a change I'm contributing the Greenplum code base over here: https://github.com/greenplum-db/gpdb/pull/1983 While it is true that 64 bit atomics are mostly a no-op for Postgres right now, perhaps this patch could still be useful. To make it easier

[HACKERS] [PATCH] Off-by-one error in logical slot resource retention

2017-03-08 Thread Craig Ringer
Hi all I've found a minor off-by-one error in the resource retention logic for logical slots, where we treat confirmed_flush as meaning "flushed up to and including this LSN". Seems reasonable, but the rest of the code treats it as "flushed up to but excluding this LSN". In particular, we treat

Re: [HACKERS] Patch: Write Amplification Reduction Method (WARM)

2017-03-08 Thread Robert Haas
On Wed, Mar 8, 2017 at 2:30 PM, Alvaro Herrera wrote: > Not really -- it's a bit slower actually in a synthetic case measuring > exactly the slowed-down case. See > https://www.postgresql.org/message-id/cad__ougk12zqmwwjzim-yyud1y8jmmy6x9yectnif3rpp6h...@mail.gmail.com

Re: [HACKERS] Gather Merge

2017-03-08 Thread Robert Haas
On Mon, Feb 20, 2017 at 1:35 AM, Rushabh Lathia wrote: > Thanks Amit for raising this point. I was not at all aware of mark/restore. > I tried to come up with the case, but haven't found such case. > > For now here is the patch with comment update. Sorry for the delay

Re: [HACKERS] contrib modules and relkind check

2017-03-08 Thread Amit Langote
On 2017/03/09 11:51, Michael Paquier wrote: > On Wed, Mar 8, 2017 at 5:10 PM, Amit Langote > wrote: >> On 2017/03/08 16:47, Michael Paquier wrote: >>> Only regular tables are tested as valid objects. Testing toast tables >>> is not worth the complication. Could you

Re: [HACKERS] contrib modules and relkind check

2017-03-08 Thread Michael Paquier
On Wed, Mar 8, 2017 at 5:10 PM, Amit Langote wrote: > On 2017/03/08 16:47, Michael Paquier wrote: >> Only regular tables are tested as valid objects. Testing toast tables >> is not worth the complication. Could you add as well a matview? > > Done in the attached

Re: [HACKERS] Cost model for parallel CREATE INDEX

2017-03-08 Thread Robert Haas
On Wed, Mar 8, 2017 at 8:45 PM, Peter Geoghegan wrote: >> This part I'm not sure about. I think people care quite a lot about >> pg_restore speed, because they are often down when they're running it. >> And they may have oodles mode CPUs that parallel restore can use >> without

Re: [HACKERS] Parallel Append implementation

2017-03-08 Thread Robert Haas
On Wed, Mar 8, 2017 at 2:00 AM, Amit Khandekar wrote: > Yeah, that seems to be right in most of the cases. The only cases > where your formula seems to give too few workers is for something like > : (2, 8, 8). For such subplans, we should at least allocate 8 workers. > It

Re: [HACKERS] Cost model for parallel CREATE INDEX

2017-03-08 Thread Peter Geoghegan
On Wed, Mar 8, 2017 at 5:33 PM, Robert Haas wrote: >> pg_restore will avoid parallelism (that will happen by setting >> "max_parallel_workers_maintenance = 0" when it runs), not because it >> cannot trust the cost model, but because it prefers to parallelize >> things its

Re: [HACKERS] Supporting huge pages on Windows

2017-03-08 Thread Tsunakawa, Takayuki
From: pgsql-hackers-ow...@postgresql.org > [mailto:pgsql-hackers-ow...@postgresql.org] On Behalf Of Ashutosh Sharma > To start with, I ran the regression test-suite and didn't find any failures. > But, then I am not sure if huge_pages are getting used or not. However, > upon checking the settings

Re: [HACKERS] Cost model for parallel CREATE INDEX

2017-03-08 Thread Robert Haas
On Sun, Mar 5, 2017 at 7:14 PM, Peter Geoghegan wrote: > On Sat, Mar 4, 2017 at 2:15 PM, Peter Geoghegan wrote: >> So, I agree with Robert that we should actually use heap size for the >> main, initial determination of # of workers to use, but we still need >> to

Re: [HACKERS] [COMMITTERS] pgsql: Use asynchronous connect API in libpqwalreceiver

2017-03-08 Thread Andrew Dunstan
On 03/08/2017 08:33 AM, Peter Eisentraut wrote: > On 3/6/17 09:38, Peter Eisentraut wrote: >> On 3/4/17 01:45, Petr Jelinek wrote: >>> If that's the case, the attached should fix it, but I have no way of >>> testing it on windows, I can only say that it still works on my machine >>> so at least

Re: [HACKERS] Print correct startup cost for the group aggregate.

2017-03-08 Thread Robert Haas
On Sun, Mar 5, 2017 at 11:32 PM, Ashutosh Bapat wrote: >> I think there have been >> previous discussions of switching over to the practice for which you >> are advocating here, but my impression (without researching) is that >> the current practice is more like

Re: [HACKERS] on_dsm_detach() callback and parallel tuplesort BufFile resource management

2017-03-08 Thread Robert Haas
On Mon, Mar 6, 2017 at 7:33 PM, Peter Geoghegan wrote: > Recap > = > > A design goal of parallel tuplesort is that the parallel case be as > close to possible as the serial case is already. Very little new code > is needed in tuplesort.c and logtape.c, most of which is about

Re: [HACKERS] Partition-wise join for join between (declaratively) partitioned tables

2017-03-08 Thread Robert Haas
On Wed, Mar 1, 2017 at 3:56 AM, Ashutosh Bapat wrote: >> 2. If the PartitionJoinPath emerges as the best path, we create paths >> for each of the remaining child-joins. Then we collect paths with >> properties same as the given PartitionJoinPath, one from each >>

Re: [HACKERS] [GSoC] Personal presentation and request for clarification

2017-03-08 Thread Robert Haas
On Thu, Mar 2, 2017 at 6:15 PM, João Miguel Afonso wrote: > The project that most caught my eye was on "Implementing push-based query > executor". > Although it completely fits my capabilities and current research, I have > some concerns on "The ability to

Re: [HACKERS] foreign partition DDL regression tests

2017-03-08 Thread Amit Langote
On 2017/03/09 1:28, Robert Haas wrote: > On Tue, Feb 21, 2017 at 8:40 PM, Amit Langote > wrote: >> Ashutosh Bapat pointed out [0] that regression tests are missing for the >> foreign partition DDL commands. Attached patch takes care of that. > > Committed.

Re: [HACKERS] Need a builtin way to run all tests faster manner

2017-03-08 Thread Michael Paquier
On Thu, Mar 9, 2017 at 6:49 AM, Andres Freund wrote: > On 2017-03-08 16:32:49 -0500, Peter Eisentraut wrote: >> On 3/6/17 19:53, Andres Freund wrote: >> > I'm just not quite sure what the best way is to make it easier to run >> > tests in parallel within the tree. >> >> make

Re: [HACKERS] WIP: [[Parallel] Shared] Hash

2017-03-08 Thread Thomas Munro
On Wed, Mar 8, 2017 at 1:15 PM, Tom Lane wrote: > Andres Freund writes: >> +++ b/src/include/storage/barrier.h >> +#include "postgres.h" > >> Huh, that normally shouldn't be in a header. I see you introduced that >> in a bunch of other places too - that

Re: [HACKERS] Need a builtin way to run all tests faster manner

2017-03-08 Thread Andres Freund
On 2017-03-08 16:32:49 -0500, Peter Eisentraut wrote: > On 3/6/17 19:53, Andres Freund wrote: > > I'm just not quite sure what the best way is to make it easier to run > > tests in parallel within the tree. > > make check-world -j2 seems to run fine for me. Hm, I at least used to get a lot of

Re: [HACKERS] Write Ahead Logging for Hash Indexes

2017-03-08 Thread Robert Haas
On Tue, Mar 7, 2017 at 6:41 PM, Robert Haas wrote: >>> Great, thanks. 0001 looks good to me now, so committed. >> >> Committed 0002. > > Here are some initial review thoughts on 0003 based on a first read-through. More thoughts on the main patch: The text you've added to

Re: [HACKERS] Need a builtin way to run all tests faster manner

2017-03-08 Thread Peter Eisentraut
On 3/6/17 19:53, Andres Freund wrote: > I'm just not quite sure what the best way is to make it easier to run > tests in parallel within the tree. make check-world -j2 seems to run fine for me. With higher -j I appear to be running out of memory or disks space, so I haven't checked that any

Re: [HACKERS] Reporting planning time with EXPLAIN

2017-03-08 Thread Stephen Frost
Ashutosh, * Ashutosh Bapat (ashutosh.ba...@enterprisedb.com) wrote: > On Tue, Mar 7, 2017 at 9:23 PM, Stephen Frost wrote: > > I'm going through these with an eye towards committing them soon. I've > > already adjusted some of the documentation and comments per our earlier >

Re: [HACKERS] SQL/JSON in PostgreSQL

2017-03-08 Thread Robert Haas
On Tue, Mar 7, 2017 at 2:38 PM, Andres Freund wrote: > On 2017-03-07 12:21:59 +0300, Oleg Bartunov wrote: >> On 2017-03-03 15:49:38 -0500, David Steele wrote: >> > I propose we move this patch to the 2017-07 CF so further development >> > and review can be done without haste

Re: [HACKERS] SQL/JSON in PostgreSQL

2017-03-08 Thread Magnus Hagander
On Wed, Mar 8, 2017 at 11:48 AM, Peter van Hardenberg wrote: > Small point of order: YAML is not strictly a super-set of JSON. > > Editorializing slightly, I have not seen much interest in the world for > YAML support though I'd be interested in evidence to the contrary. > > The

Re: [HACKERS] SQL/JSON in PostgreSQL

2017-03-08 Thread Peter van Hardenberg
Small point of order: YAML is not strictly a super-set of JSON. Editorializing slightly, I have not seen much interest in the world for YAML support though I'd be interested in evidence to the contrary. On Tue, Mar 7, 2017 at 1:43 PM, Sven R. Kunze wrote: > Hi, > > about the

Re: [HACKERS] Patch: Write Amplification Reduction Method (WARM)

2017-03-08 Thread Alvaro Herrera
Robert Haas wrote: > On Wed, Mar 8, 2017 at 12:14 PM, Alvaro Herrera > wrote: > > Alvaro Herrera wrote: > >> Here's a rebased set of patches. This is the same Pavan posted; I only > >> fixed some whitespace and a trivial conflict in indexam.c, per > >> 9b88f27cb42f. >

Re: [HACKERS] background sessions

2017-03-08 Thread Pavel Stehule
Hi 2017-03-01 3:35 GMT+01:00 Peter Eisentraut : > > For additional entertainment, I include patches that integrate > > background sessions into dblink. So dblink can open a connection to a > > background session, and then you can use the existing dblink

Re: [HACKERS] Write Ahead Logging for Hash Indexes

2017-03-08 Thread Robert Haas
On Wed, Mar 8, 2017 at 7:45 AM, Amit Kapila wrote: >> I still think this is a bad idea. Releasing and reacquiring the lock >> on the master doesn't prevent the standby from seeing intermediate >> states; the comment, if I understand correctly, is just plain wrong. > I

Re: [HACKERS] SQL/JSON in PostgreSQL

2017-03-08 Thread Oleg Bartunov
On Wed, Mar 8, 2017 at 7:05 AM, David Steele wrote: > On 3/7/17 11:38 AM, Andres Freund wrote: > > <...> > > We have a plenty of time and we dedicate one full-time developer for >>> this project. >>> >> >> How about having that, and perhaps others, developer participate in

Re: [HACKERS] Parallel bitmap heap scan

2017-03-08 Thread Robert Haas
On Wed, Mar 8, 2017 at 1:18 PM, Tom Lane wrote: > Robert Haas writes: >> What I'm using is: > >> Configured with: >> --prefix=/Applications/Xcode.app/Contents/Developer/usr >> --with-gxx-include-dir=/usr/include/c++/4.2.1 >> Apple LLVM version 7.0.2

Re: [HACKERS] Parallel bitmap heap scan

2017-03-08 Thread Tom Lane
Robert Haas writes: > What I'm using is: > Configured with: > --prefix=/Applications/Xcode.app/Contents/Developer/usr > --with-gxx-include-dir=/usr/include/c++/4.2.1 > Apple LLVM version 7.0.2 (clang-700.1.81) > Target: x86_64-apple-darwin14.5.0 > Thread model: posix Hm.

Re: [HACKERS] Patch: Write Amplification Reduction Method (WARM)

2017-03-08 Thread Robert Haas
On Wed, Mar 8, 2017 at 12:14 PM, Alvaro Herrera wrote: > Alvaro Herrera wrote: >> Here's a rebased set of patches. This is the same Pavan posted; I only >> fixed some whitespace and a trivial conflict in indexam.c, per 9b88f27cb42f. > > Jaime noted that I forgot the

Re: [HACKERS] SQL/JSON in PostgreSQL

2017-03-08 Thread Oleg Bartunov
On Wed, Mar 8, 2017 at 12:43 AM, Sven R. Kunze wrote: > Hi, > > about the datetime issue: as far as I know, JSON does not define a > serialization format for dates and timestamps. > > On the other hand, YAML (as a superset of JSON) already supports a > language-independent

Re: [HACKERS] Hash support for grouping sets

2017-03-08 Thread Andrew Gierth
> "Mark" == Mark Dilger writes: Mark> Hi Andrew, Mark> Reviewing the patch a bit more, I find it hard to understand the Mark> comment about passing -1 as a flag for finalize_aggregates. Any Mark> chance you can spend a bit more time word-smithing that code

Re: [HACKERS] Explicit subtransactions for PL/Tcl

2017-03-08 Thread Victor Wagner
On Wed, 8 Mar 2017 16:49:33 +0100 Pavel Stehule wrote: > > I did a review of this patch First, thank you for you effort. I already begin to think that nobody is really interesting in PL/Tcl stuff. > 1. This functionality has sense and nobody was against this

Re: [HACKERS] Parallel bitmap heap scan

2017-03-08 Thread Robert Haas
On Wed, Mar 8, 2017 at 12:53 PM, Tom Lane wrote: >> Thanks. Sorry for the hassle; my compiler isn't as picky about this >> as I would like, and apparently Dilip's isn't either. > > Might be interesting to see whether -O level affects it. In principle, > whether you get the

Re: [HACKERS] Hash support for grouping sets

2017-03-08 Thread Mark Dilger
> On Mar 8, 2017, at 9:40 AM, Andrew Gierth wrote: > >> "Mark" == Mark Dilger writes: > > Mark> Hi Andrew, > > Mark> Reviewing the patch a bit more, I find it hard to understand the > Mark> comment about passing -1 as a flag for

Re: [HACKERS] Need a builtin way to run all tests faster manner

2017-03-08 Thread Robert Haas
On Tue, Mar 7, 2017 at 11:23 PM, Andres Freund wrote: > Personally that's not addressing my main concern, which is that the > latency of getting done with some patch/topic takes a long while. If I > have to wait for the buildfarm to check some preliminary patch, I still > have

Re: [HACKERS] Parallel bitmap heap scan

2017-03-08 Thread Tom Lane
Robert Haas writes: > On Wed, Mar 8, 2017 at 12:45 PM, Tom Lane wrote: >> Jeff Janes writes: >>> I'm getting some compiler warnings in gcc version 4.4.7 20120313 (Red Hat >>> 4.4.7-17) (GCC): >> Me too. Fix pushed. > Thanks.

Re: [HACKERS] [GSoC] Push-based query executor discussion

2017-03-08 Thread Robert Haas
On Mon, Mar 6, 2017 at 11:20 AM, Arseny Sher wrote: > I would like to work on push-based executor [1] during GSoC, so I'm > writing to introduce myself and start the discussion of the project. I > think I should mention beforehand that the subject is my master's > thesis

Re: [HACKERS] Parallel bitmap heap scan

2017-03-08 Thread Robert Haas
On Wed, Mar 8, 2017 at 12:45 PM, Tom Lane wrote: > Jeff Janes writes: >> I'm getting some compiler warnings in gcc version 4.4.7 20120313 (Red Hat >> 4.4.7-17) (GCC): > > Me too. Fix pushed. Thanks. Sorry for the hassle; my compiler isn't as picky

[HACKERS] updating parallel.sgml

2017-03-08 Thread Robert Haas
Here's a patch which updates parallel.sgml for the new parallel scan types which have recently been committed, and also expands the explanation of parallel joins slightly. I hope everyone will find this useful in understanding what new capabilities we now have, and what remains to be done in the

Re: [HACKERS] Parallel bitmap heap scan

2017-03-08 Thread Tom Lane
Jeff Janes writes: > I'm getting some compiler warnings in gcc version 4.4.7 20120313 (Red Hat > 4.4.7-17) (GCC): Me too. Fix pushed. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your

Re: [HACKERS] Example Custom Scan Provider Implementation?

2017-03-08 Thread Eric Ridge
On Tue, Mar 7, 2017 at 6:39 PM Amit Langote wrote: > > Here you go: https://github.com/kaigai/ctidscan Thanks for the link, Amit! I think that'll get me bootstrapped! This was proposed originally [1] to go into contrib/, but that didn't > happen somehow. > Too

Re: [HACKERS] Hash support for grouping sets

2017-03-08 Thread Andrew Gierth
> "Mark" == Mark Dilger writes: Mark> Hi Andrew, Mark> Reviewing the patch a bit more, I find it hard to understand the Mark> comment about passing -1 as a flag for finalize_aggregates. Any Mark> chance you can spend a bit more time word-smithing that code

Re: [HACKERS] Parallel bitmap heap scan

2017-03-08 Thread Jeff Janes
On Wed, Mar 8, 2017 at 9:08 AM, Robert Haas wrote: > On Wed, Mar 8, 2017 at 11:20 AM, Dilip Kumar > wrote: > > Right, done that way > > This didn't compile because you bobbled some code in > src/backend/nodes, but it was a trivial mistake so I fixed

Re: [HACKERS] Poor memory context performance in large hash joins

2017-03-08 Thread Tom Lane
Andres Freund writes: > On 2017-03-07 13:06:39 -0500, Tom Lane wrote: >> The hashjoin issue is certainly new, and the reorderbuffer issue can't >> go back further than 9.4. So my inclination is to patch back to 9.4 >> and call it good. > That works for me. If we find

Re: [HACKERS] Patch: Write Amplification Reduction Method (WARM)

2017-03-08 Thread Robert Haas
On Wed, Mar 8, 2017 at 12:00 PM, Alvaro Herrera wrote: > Here's a rebased set of patches. This is the same Pavan posted; I only > fixed some whitespace and a trivial conflict in indexam.c, per 9b88f27cb42f. No attachments. -- Robert Haas EnterpriseDB:

Re: [HACKERS] Parallel bitmap heap scan

2017-03-08 Thread Robert Haas
On Wed, Mar 8, 2017 at 11:20 AM, Dilip Kumar wrote: > Right, done that way This didn't compile because you bobbled some code in src/backend/nodes, but it was a trivial mistake so I fixed it. Committed with that fix and a bunch of minor cosmetic changes. -- Robert Haas

Re: [HACKERS] patch: function xmltable

2017-03-08 Thread Alvaro Herrera
Pavel Stehule wrote: > 2017-03-08 17:32 GMT+01:00 Alvaro Herrera : > > > For daily work the default schema support is much more interesting. > > > > Let's see that one, then. It was part of the original submission so > > depending on how the patch we looks can still

Re: [HACKERS] Patch: Write Amplification Reduction Method (WARM)

2017-03-08 Thread Alvaro Herrera
Here's a rebased set of patches. This is the same Pavan posted; I only fixed some whitespace and a trivial conflict in indexam.c, per 9b88f27cb42f. -- Álvaro Herrerahttps://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services -- Sent via

Re: [HACKERS] Cannot shutdown subscriber after DROP SUBSCRIPTION

2017-03-08 Thread Fujii Masao
On Wed, Mar 8, 2017 at 9:05 PM, Masahiko Sawada wrote: > On Wed, Feb 8, 2017 at 12:04 AM, Fujii Masao wrote: >> On Tue, Feb 7, 2017 at 2:13 AM, Petr Jelinek >> wrote: >>> On 06/02/17 17:33, Fujii Masao wrote: On

Re: [HACKERS] new gcc 7.0.1 warnings

2017-03-08 Thread Pavel Stehule
2017-03-08 17:33 GMT+01:00 Alvaro Herrera : > Pavel Stehule wrote: > > 2017-02-18 18:35 GMT+01:00 Tom Lane : > > > > > Pavel Stehule writes: > > > > Do the warnings go away if you add some explicit guard to the precision > >

Re: [HACKERS] patch: function xmltable

2017-03-08 Thread Pavel Stehule
2017-03-08 17:32 GMT+01:00 Alvaro Herrera : > Pavel Stehule wrote: > > 2017-03-08 17:01 GMT+01:00 Alvaro Herrera : > > > > I didn't add the change you proposed here to keep COLUMNS optional; > > > instead, I just made COLUMNS mandatory. I think

Re: [HACKERS] Hash support for grouping sets

2017-03-08 Thread Mark Dilger
Hi Andrew, Reviewing the patch a bit more, I find it hard to understand the comment about passing -1 as a flag for finalize_aggregates. Any chance you can spend a bit more time word-smithing that code comment? @@ -1559,7 +1647,9 @@ prepare_projection_slot(AggState *aggstate, TupleTableSlot

Re: [HACKERS] adding an immutable variant of to_date

2017-03-08 Thread Andreas Karlsson
On 03/07/2017 09:56 PM, Sven R. Kunze wrote: On 07.03.2017 03:21, Andreas Karlsson wrote: 1) I do not think we currently allow setting the locale like this anywhere, so this will introduce a new concept to PostgreSQL. And you will probably need to add support for caching per locale. Good to

Re: [HACKERS] new gcc 7.0.1 warnings

2017-03-08 Thread Alvaro Herrera
Pavel Stehule wrote: > 2017-02-18 18:35 GMT+01:00 Tom Lane : > > > Pavel Stehule writes: > > Do the warnings go away if you add some explicit guard to the precision > > variable, say like this: > > > > { > > int

Re: [HACKERS] patch: function xmltable

2017-03-08 Thread Alvaro Herrera
Pavel Stehule wrote: > 2017-03-08 17:01 GMT+01:00 Alvaro Herrera : > > I didn't add the change you proposed here to keep COLUMNS optional; > > instead, I just made COLUMNS mandatory. I think what you propose here > > is not entirely out of the question, but you left out

Re: [HACKERS] foreign partition DDL regression tests

2017-03-08 Thread Robert Haas
On Tue, Feb 21, 2017 at 8:40 PM, Amit Langote wrote: > Ashutosh Bapat pointed out [0] that regression tests are missing for the > foreign partition DDL commands. Attached patch takes care of that. Committed. I didn't do anything about Ashutosh's comment that we

Re: [HACKERS] Parallel bitmap heap scan

2017-03-08 Thread Dilip Kumar
On Wed, Mar 8, 2017 at 8:28 PM, Robert Haas wrote: > How about adding a regression test? Added > > bitmap_subplan_mark_shared could use castNode(), which seems like it > would be better style. Maybe some other places, too. > > + ParallelBitmapPopulate > +

Re: [HACKERS] CREATE/ALTER ROLE PASSWORD ('value' USING 'method')

2017-03-08 Thread Joe Conway
On 03/07/2017 08:29 PM, Tom Lane wrote: > Michael Paquier writes: >> here is a separate thread dedicated to the following extension for >> CREATE/ALTER ROLE: PASSWORD ('value' USING 'method'). > > The parentheses seem weird ... do we really need those? +1 > +

Re: [HACKERS] new gcc 7.0.1 warnings

2017-03-08 Thread Pavel Stehule
2017-03-08 16:59 GMT+01:00 Peter Eisentraut < peter.eisentr...@2ndquadrant.com>: > On 2/18/17 02:08, Pavel Stehule wrote: > > I am checking new Fedora 26, where new gcc compiler is used. > > > > float.c: In function ‘float4out’: > > float.c:382:41: warning: ‘%.*g’ directive output may be

Re: [HACKERS] patch: function xmltable

2017-03-08 Thread Pavel Stehule
2017-03-08 17:01 GMT+01:00 Alvaro Herrera : > Pavel Stehule wrote: > > Hi > > > > I used your idea about special columns when COLUMNS are not explicitly > > defined. > > > > All lines that you are dislike removed. > > I just pushed XMLTABLE, after some additional

Re: [HACKERS] Hash support for grouping sets

2017-03-08 Thread Mark Dilger
> On Mar 8, 2017, at 5:47 AM, Andrew Gierth wrote: > >> "Mark" == Mark Dilger writes: > > Mark> On my MacBook, `make check-world` gives differences in the > Mark> contrib modules: > > Thanks! Latest cleaned up version of patch is

Re: [HACKERS] patch: function xmltable

2017-03-08 Thread Alvaro Herrera
Pavel Stehule wrote: > Hi > > I used your idea about special columns when COLUMNS are not explicitly > defined. > > All lines that you are dislike removed. I just pushed XMLTABLE, after some additional changes. Please test it thoroughly and report any problems. I didn't add the change you

Re: [HACKERS] new gcc 7.0.1 warnings

2017-03-08 Thread Peter Eisentraut
On 2/18/17 02:08, Pavel Stehule wrote: > I am checking new Fedora 26, where new gcc compiler is used. > > float.c: In function ‘float4out’: > float.c:382:41: warning: ‘%.*g’ directive output may be truncated > writing between 1 and 310 bytes into a region of size 65 > [-Wformat-truncation=] >

Re: [HACKERS] Explicit subtransactions for PL/Tcl

2017-03-08 Thread Pavel Stehule
Hi 2017-01-08 18:57 GMT+01:00 Victor Wagner : > > Collegues! > > Recently I've found out that PL/Python have very nice feature - explicit > subtransaction object, which allows to execute block of code in the > context of subtransaction. > > I've quite surprised that other PL

Re: [HACKERS] REINDEX CONCURRENTLY 2.0

2017-03-08 Thread Andreas Karlsson
On 03/08/2017 03:48 AM, Robert Haas wrote: On Sun, Mar 5, 2017 at 7:13 PM, Andreas Karlsson wrote: And I would argue that his feature is useful for quite many, based on my experience running a semi-large database. Index bloat happens and without REINDEX CONCURRENTLY it can

Re: [HACKERS] Hash support for grouping sets

2017-03-08 Thread Mark Dilger
> On Mar 8, 2017, at 2:30 AM, Andrew Gierth wrote: > >> "Mark" == Mark Dilger writes: > > Mark> On linux/gcc the patch generates a warning in nodeAgg.c that is > Mark> fairly easy to fix. Using -Werror to make catching the error >

Re: [HACKERS] foreign partition DDL regression tests

2017-03-08 Thread Robert Haas
On Tue, Mar 7, 2017 at 11:18 PM, Ashutosh Bapat wrote: >> I agree that we could do that, but what value would it have? It just >> forces the user to spend two SQL commands doing what could otherwise >> be done in one. > > I don't think it's going to be two

Re: [HACKERS] Removing #include "postgres.h" from a couple of headers

2017-03-08 Thread Tom Lane
... BTW, a bit of grepping shows that there are still significant violations of this policy with respect to header-driven inclusion of postgres_fe.h and c.h. Also, plpgsql is doing it in the unapproved fashion. Cleaning these up will take a bit more work, since we'll have to actually add

Re: [HACKERS] Parallel bitmap heap scan

2017-03-08 Thread Robert Haas
Reviewing 0003: How about adding a regression test? bitmap_subplan_mark_shared could use castNode(), which seems like it would be better style. Maybe some other places, too. + ParallelBitmapPopulate + Waiting for the leader to populate the TidBitmap. + + If you

Re: [HACKERS] Removing #include "postgres.h" from a couple of headers

2017-03-08 Thread Tom Lane
Robert Haas writes: > On Wed, Mar 8, 2017 at 3:55 AM, Thomas Munro > wrote: >> There are also instances in regcustom.h and snowball's header.h -- are >> those special cases? > I will leave this question to someone wiser (or more

Re: [HACKERS] Parallel bitmap heap scan

2017-03-08 Thread Dilip Kumar
On Wed, Mar 8, 2017 at 6:42 PM, Robert Haas wrote: > I don't think I understand exactly why this system might be prone to a > little bit of extra prefetching - can you explain further? Let me explain with an example, suppose there are 2 workers prefetching jointly, lets

Re: [HACKERS] port of INSTALL file generation to XSLT

2017-03-08 Thread Peter Eisentraut
On 3/1/17 20:23, Magnus Hagander wrote: > On Wed, Mar 1, 2017 at 3:58 AM, Peter Eisentraut > > wrote: > > On 2/28/17 08:57, Magnus Hagander wrote: > > It appears we need pandoc 1.13 to get the good output.

Re: [HACKERS] Implementation of SASLprep for SCRAM-SHA-256

2017-03-08 Thread Robert Haas
On Tue, Mar 7, 2017 at 10:01 PM, Michael Paquier wrote: > RFC5802 (https://tools.ietf.org/html/rfc5802) regarding the > implementation of SCRAM, needs to have passwords normalized as per > RFC4013 (https://tools.ietf.org/html/rfc4013) using SASLprep, which is > actually

Re: [HACKERS] Partitioned tables and relfilenode

2017-03-08 Thread Robert Haas
On Wed, Mar 8, 2017 at 5:36 AM, Amit Langote wrote: >> I don't quite understand the need for the change to set_rel_size(). >> The rte->inh case is handled before reaching the new code, and IIUC >> the !rte->inh case should never happen given the changes to >>

Re: [HACKERS] [COMMITTERS] pgsql: Use asynchronous connect API in libpqwalreceiver

2017-03-08 Thread Peter Eisentraut
On 3/6/17 09:38, Peter Eisentraut wrote: > On 3/4/17 01:45, Petr Jelinek wrote: >> If that's the case, the attached should fix it, but I have no way of >> testing it on windows, I can only say that it still works on my machine >> so at least it hopefully does not make things worse. > > Committed

Re: [HACKERS] PATCH: psql show index with type info

2017-03-08 Thread Stephen Frost
Ashutosh, * Ashutosh Bapat (ashutosh.ba...@enterprisedb.com) wrote: > On Mon, Mar 6, 2017 at 7:54 PM, Amos Bird wrote: > > Well, the prefix is used to differentiate other \d commands, like > > this, > > > > amos=# \ditv > > List of relations > > Schema

Re: [HACKERS] Parallel seq. plan is not coming against inheritance or partition table

2017-03-08 Thread Robert Haas
On Wed, Mar 8, 2017 at 7:04 AM, Amit Kapila wrote: > On Wed, Mar 8, 2017 at 8:28 AM, Robert Haas wrote: >> On Tue, Mar 7, 2017 at 9:24 PM, Amit Kapila wrote: >>> I think it can give us benefit in >>> such cases as well

Re: [HACKERS] Skip all-visible pages during second HeapScan of CIC

2017-03-08 Thread Stephen Frost
* Andres Freund (and...@anarazel.de) wrote: > On 2017-03-07 21:38:40 -0500, Robert Haas wrote: > > > I wonder however, if careful snapshot managment couldn't solve this as > > > well. I have *not* thought a lot about this, but afaics we can easily > > > prevent all-visible from being set in cases

Re: [HACKERS] Adding the optional clause 'AS' in CREATE TRIGGER

2017-03-08 Thread Peter Eisentraut
On 3/8/17 04:12, Okano, Naoki wrote: > Peter Eisentraut wrote: >> I have a feeling that this was proposed a few times in the ancient past >> but did not go through because of locking issues. I can't find any >> emails about it through. Does anyone remember? Have you thought about >> locking

Re: [HACKERS] Removing #include "postgres.h" from a couple of headers

2017-03-08 Thread Robert Haas
On Wed, Mar 8, 2017 at 3:55 AM, Thomas Munro wrote: > Over in another thread it was pointed out that a patch I submitted > broke a project rule by including "postgres.h" in a header. Here is a > patch to remove it from dsa.h where I made the same mistake, and also

Re: [HACKERS] Skip all-visible pages during second HeapScan of CIC

2017-03-08 Thread Stephen Frost
* Pavan Deolasee (pavan.deola...@gmail.com) wrote: > On Wed, Mar 8, 2017 at 7:33 AM, Robert Haas wrote: > > > On Tue, Mar 7, 2017 at 4:26 PM, Stephen Frost wrote: > > > Right, that's what I thought he was getting at and my general thinking > > > was

Re: [HACKERS] Parallel bitmap heap scan

2017-03-08 Thread Robert Haas
On Wed, Mar 8, 2017 at 1:49 AM, Dilip Kumar wrote: > On Tue, Mar 7, 2017 at 10:10 PM, Dilip Kumar wrote: >>> It's not about speed. It's about not forgetting to prefetch. Suppose >>> that worker 1 becomes the prefetch worker but then doesn't return

Re: [HACKERS] wait events for disk I/O

2017-03-08 Thread Rajkumar Raghuwanshi
On Wed, Mar 8, 2017 at 4:50 PM, Rushabh Lathia wrote: > I am attaching another version of the patch, as I found stupid mistake > in the earlier version of patch, where I missed to initialize initial > value to > WaitEventIO enum. Also earlier version was not getting

Re: [HACKERS] Foreign Join pushdowns not working properly for outer joins

2017-03-08 Thread David Rowley
On 7 March 2017 at 01:22, Ashutosh Bapat wrote: > On Mon, Mar 6, 2017 at 1:29 PM, David Rowley > wrote: >> On 6 March 2017 at 18:51, Etsuro Fujita wrote: >>> On 2017/03/06 11:05, David Rowley wrote: >>

  1   2   >