Re: [HACKERS] logical decoding of two-phase transactions

2017-03-01 Thread Stas Kelvich
> On 2 Mar 2017, at 01:20, Petr Jelinek wrote: > > The info gets removed on COMMIT PREPARED but at that point > there is no real difference between replicating it as 2pc or 1pc since > the 2pc behavior is for all intents and purposes lost at that point. > If we

Re: [HACKERS] UPDATE of partition key

2017-03-01 Thread Amit Langote
On 2017/02/26 4:01, David G. Johnston wrote: > IIUC ​it is already possible, for those who care to do so, to get a > serialization failure in this scenario by upgrading isolation to repeatable > read. Maybe, this can be added as a note in the documentation. Thanks, Amit -- Sent via

Re: [HACKERS] user mapping messages

2017-03-01 Thread Ashutosh Bapat
On Thu, Feb 23, 2017 at 8:06 PM, Andrew Dunstan wrote: > > While reviewing the IF NOT EXISTS patch for CREATE USER MAPPING I > noticed that in several places we treat the user name as the name of the > user mapping. Strictly ISTM that user mappings are really

Re: [HACKERS] patch: function xmltable

2017-03-01 Thread Pavel Stehule
Hi 2017-03-02 1:12 GMT+01:00 Alvaro Herrera : > > I've been giving this a look. I started by tweaking the docs once > again, and while verifying that the example works as expected, I > replayed what I have in sgml: > > ... begin SGML paste ... > > For

Re: [HACKERS] \if, \elseif, \else, \endif (was Re: PSQL commands: \quit_if, \quit_unless)

2017-03-01 Thread Corey Huinker
On Thu, Mar 2, 2017 at 1:23 AM, Fabien COELHO wrote: > > Hello Corey, > > That is accurate. The only positive it has is that the user only >> experiences one error, and it's the first error that was encountered if >> reading top-to-bottom, left to right. It is an issue of

Re: [HACKERS] multivariate statistics (v24)

2017-03-01 Thread Kyotaro HORIGUCHI
Hello, At Thu, 2 Mar 2017 04:05:34 +0100, Tomas Vondra wrote in > OK, > > attached is v24 of the patch series, addressing most of the reported > issues and comments (at least I believe so). The main changes

Re: [HACKERS] PATCH: two slab-like memory allocators

2017-03-01 Thread Andres Freund
On 2017-03-02 04:47:13 +0100, Tomas Vondra wrote: > On 03/01/2017 11:55 PM, Andres Freund wrote: > > On 2017-02-28 20:29:36 -0800, Andres Freund wrote: > > > On 2017-02-28 20:18:35 -0800, Andres Freund wrote: > > > > - Andres, hoping the buildfarm turns greener > > > > > > Oh well, that didn't

Re: [HACKERS] \if, \elseif, \else, \endif (was Re: PSQL commands: \quit_if, \quit_unless)

2017-03-01 Thread Fabien COELHO
Hello Corey, That is accurate. The only positive it has is that the user only experiences one error, and it's the first error that was encountered if reading top-to-bottom, left to right. It is an issue of which we prioritize - user experience or simpler code. Hmmm. The last simpler

Re: [HACKERS] UPDATE of partition key

2017-03-01 Thread Amit Khandekar
On 23 February 2017 at 16:02, Amit Langote wrote: > >> 2. In the patch, as part of the row movement, ExecDelete() is called >> followed by ExecInsert(). This is done that way, because we want to >> have the ROW triggers on that (sub)partition executed. If a user has

Re: [HACKERS] dropping partitioned tables without CASCADE

2017-03-01 Thread Ashutosh Bapat
>> >> Isn't list_range_parted multilevel partitioned table. It gets dropped >> in the testcases. So, I guess, we already have a testcase there. > > I thought Simon meant the test case where a partition that is itself > partitioned is dropped. At least that's what I took from "... fails *on* >

Re: [HACKERS] PATCH: two slab-like memory allocators

2017-03-01 Thread Andres Freund
On 2017-03-02 04:36:23 +0100, Tomas Vondra wrote: > I've noticed two minor typos: > > 1) That is solved this by creating ... >- extra "this" > > 2) Given this, routines like pfree their corresponding context ... >- missing "find" or "determine" Will fix. > I also see you've explicitly

Re: [HACKERS] REINDEX CONCURRENTLY 2.0

2017-03-01 Thread Andres Freund
On 2017-03-01 19:25:23 -0600, Jim Nasby wrote: > On 2/28/17 11:21 AM, Andreas Karlsson wrote: > > The only downside I can see to this approach is that we no logner will > > able to reindex catalog tables concurrently, but in return it should be > > easier to confirm that this approach can be made

Re: [HACKERS] Possible spelling fixes

2017-03-01 Thread Josh Soref
0001-spelling-comments.patch Description: Binary data 0002-spelling-strings.patch Description: Binary data 0003-spelling-sgml.patch Description: Binary data 0004-spelling-variables.patch Description: Binary data 0005-spelling-misc.patch Description: Binary data -- Sent via

Re: [HACKERS] Radix tree for character conversion

2017-03-01 Thread Kyotaro HORIGUCHI
At Wed, 1 Mar 2017 14:34:23 +0900, Michael Paquier wrote in > On Tue, Feb 28, 2017 at 5:34 PM, Kyotaro HORIGUCHI > wrote: > > At Tue, 28 Feb 2017 15:20:06 +0900,

Re: [HACKERS] SerializedSnapshotData alignment

2017-03-01 Thread Noah Misch
On Mon, Feb 27, 2017 at 12:11:54PM +0530, Robert Haas wrote: > On Mon, Feb 27, 2017 at 5:13 AM, Noah Misch wrote: > > Dear 7b4ac19 authors, > > > > Field ps_snapshot_data usually receives four-byte alignment within > > ParallelIndexScanDescData, but it contains the eight-byte

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

2017-03-01 Thread Ashutosh Bapat
Updated 0001 patch with some more comments. Attaching all the patches for quick access. On Wed, Mar 1, 2017 at 2:26 PM, Ashutosh Bapat wrote: >> >> 2. If the PartitionJoinPath emerges as the best path, we create paths >> for each of the remaining child-joins.

Re: [HACKERS] \h tab-completion

2017-03-01 Thread Kyotaro HORIGUCHI
Hello, At Wed, 1 Mar 2017 08:47:15 -0500, Peter Eisentraut wrote in > On 2/3/17 07:12, Andreas Karlsson wrote: > > On 01/25/2017 07:13 AM, Michael Paquier wrote: > >> What I think you should do is making

Re: [HACKERS] SerializedSnapshotData alignment

2017-03-01 Thread Noah Misch
On Mon, Feb 27, 2017 at 03:08:35PM +1300, Thomas Munro wrote: > On Mon, Feb 27, 2017 at 2:18 PM, Noah Misch wrote: > > I wondered the same thing; if nothing else, why don't protosciurus and > > castoroides fail the same way? They do use older compilers, "Sun C 5.10 > >

Re: [HACKERS] PATCH: two slab-like memory allocators

2017-03-01 Thread Tomas Vondra
On 03/01/2017 11:55 PM, Andres Freund wrote: On 2017-02-28 20:29:36 -0800, Andres Freund wrote: On 2017-02-28 20:18:35 -0800, Andres Freund wrote: - Andres, hoping the buildfarm turns greener Oh well, that didn't work. Investigating. The fix for that was fairly trivial, and the buildfarm

Re: [HACKERS] PATCH: Make pg_stop_backup() archive wait optional

2017-03-01 Thread David Steele
On 3/1/17 5:11 PM, Jim Nasby wrote: > On 2/27/17 6:25 PM, David Steele wrote: >> The purpose of this patch is to make waiting for archive optional, with >> the default being the current behavior, i.e., to wait for all WAL to be >> archived. This functionality is already used internally by >>

Re: [HACKERS] PATCH: two slab-like memory allocators

2017-03-01 Thread Tomas Vondra
On 03/01/2017 05:18 AM, Andres Freund wrote: On 2017-02-28 10:41:22 -0800, Andres Freund wrote: Hi, On 2017-02-27 23:44:20 -0800, Andres Freund wrote: *preliminary* patch attached. This needs a good bit of polishing (primarily comment work, verifying that valgrind works), but I'm too tired

Re: [HACKERS] Patch to improve performance of replay of AccessExclusiveLock

2017-03-01 Thread Amit Kapila
On Wed, Mar 1, 2017 at 5:32 PM, David Rowley wrote: > Hackers, > > I've attached a small patch which aims to improve the performance of > AccessExclusiveLock when there are many AccessExclusiveLock stored. > I could see that your idea is quite straightforward to

Re: [HACKERS] Transactions involving multiple postgres foreign servers

2017-03-01 Thread vinayak
On 2017/02/28 16:54, Masahiko Sawada wrote: I've created a wiki page[1] describing about the design and functionality of this feature. Also it has some examples of use case, so this page would be helpful for even testing. Please refer it if you're interested in testing this feature. [1] 2PC

Re: [HACKERS] IF (NOT) EXISTS in psql-completion

2017-03-01 Thread Kyotaro HORIGUCHI
Hello, At Tue, 28 Feb 2017 10:39:01 -0500, Stephen Frost wrote in <20170228153901.gh9...@tamriel.snowman.net> > * David Fetter (da...@fetter.org) wrote: > > On Mon, Feb 27, 2017 at 11:53:17PM -0500, Stephen Frost wrote: > > > * Kyotaro HORIGUCHI

Re: [HACKERS] REINDEX CONCURRENTLY 2.0

2017-03-01 Thread Michael Paquier
On Wed, Mar 1, 2017 at 2:21 AM, Andreas Karlsson wrote: > For each table: > > 1. Create new indexes without populating them, and lock the tables and > indexes for the session. +/* + * Copy contraint flags for old index. This is safe because the old index + *

Re: [HACKERS] Two questions about Postgres parser

2017-03-01 Thread Jim Nasby
On 2/27/17 10:37 AM, Tom Lane wrote: 2. Implicit user defined type casts are not applied for COALESCE operator: That has nothing to do with whether the cast is user-defined. It has to do with not wanting to automatically unify types across type-category boundaries (in this case, numeric vs.

Re: [HACKERS] REINDEX CONCURRENTLY 2.0

2017-03-01 Thread Jim Nasby
On 2/28/17 11:21 AM, Andreas Karlsson wrote: The only downside I can see to this approach is that we no logner will able to reindex catalog tables concurrently, but in return it should be easier to confirm that this approach can be made work. Another downside is any stored regclass fields will

Re: [HACKERS] Disallowing multiple queries per PQexec()

2017-03-01 Thread Jim Nasby
On 2/28/17 2:45 PM, Andres Freund wrote: So if you don't want to allow multiple statements, use PQexecParams et al. That does leave most application authors out in the cold though, since they're using a higher level connection manager. If the maintenance burden isn't terribly high it would

Re: [HACKERS] Wrong variable type in KeepLogSeg

2017-03-01 Thread Kyotaro HORIGUCHI
At Tue, 28 Feb 2017 12:21:01 +0100, Magnus Hagander wrote in magnus> > Hello, I found a variable definition with wrong type magnus> > specification in KeepLogSeg, which doesn't harm anything. magnus>

Re: [HACKERS] I propose killing PL/Tcl's "modules" infrastructure

2017-03-01 Thread Jim Nasby
On 2/27/17 2:42 PM, Tom Lane wrote: + SET pltcl.start_proc = 'no_such_function'; + select tcl_int4add(1, 2); + ERROR: function no_such_function() does not exist Can the error message be more explicit somehow? Otherwise people will be quite confused as to where no_such_function() is coming

Re: [HACKERS] PATCH: Make pg_stop_backup() archive wait optional

2017-03-01 Thread Jim Nasby
On 2/27/17 6:25 PM, David Steele wrote: The purpose of this patch is to make waiting for archive optional, with the default being the current behavior, i.e., to wait for all WAL to be archived. This functionality is already used internally by pg_basebackup, so the only real change is to expose

Re: [HACKERS] GSoC 2017

2017-03-01 Thread Jim Nasby
On 2/27/17 4:52 PM, Thomas Munro wrote: By the way, that page claims that PostgreSQL runs on Irix and Tru64, which hasn't been true for a few years. There could be a GSoC project to add support for those back in... ;P -- Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX Experts in

Re: [HACKERS] mat views stats

2017-03-01 Thread Michael Paquier
On Thu, Mar 2, 2017 at 7:20 AM, Jim Mlodgenski wrote: > > > On Sun, Feb 26, 2017 at 11:49 AM, Robert Haas wrote: >> >> On Wed, Feb 22, 2017 at 11:13 AM, Jim Nasby >> wrote: >> > Certainly easier, but I don't think it'd be

Re: [HACKERS] 2017-03 Commitfest In Progress

2017-03-01 Thread Tom Lane
Thomas Munro writes: > On Thu, Mar 2, 2017 at 4:42 AM, David Steele wrote: >> The 2017-03 commitfest is now in progress. Here's the breakdown: >> >> Needs review: 128 >> Waiting on Author: 26 >> Ready for Committer: 26 >> Total: 180 > Not

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

2017-03-01 Thread Magnus Hagander
On Wed, Mar 1, 2017 at 3:58 AM, Peter Eisentraut < peter.eisentr...@2ndquadrant.com> wrote: > On 2/28/17 08:57, Magnus Hagander wrote: > > It appears we need pandoc 1.13 to get the good output. This won't be > > available until Debian stretch. > > > > So for PG10, I propose the

Re: [HACKERS] logical decoding of two-phase transactions

2017-03-01 Thread Craig Ringer
On 2 March 2017 at 06:20, Petr Jelinek wrote: > If I understand you correctly you are saying that if PREPARE is being > decoded, we can load the GID from the 2pc info in memory about the > specific 2pc. The info gets removed on COMMIT PREPARED but at that point >

Re: [HACKERS] Restricting maximum keep segments by repslots

2017-03-01 Thread Kyotaro HORIGUCHI
At Wed, 1 Mar 2017 12:18:07 -0500, Peter Eisentraut wrote in <98538b00-42ae-6a6b-f852-50b3c937a...@2ndquadrant.com> > On 2/27/17 22:27, Kyotaro HORIGUCHI wrote: > > This patch adds a GUC to put a limit to the number of segments > > that replication slots can

Re: [HACKERS] Restricting maximum keep segments by repslots

2017-03-01 Thread Kyotaro HORIGUCHI
At Wed, 1 Mar 2017 12:17:43 -0500, Peter Eisentraut wrote in > On 2/27/17 23:27, Petr Jelinek wrote: > >>> WARNING: restart LSN of replication slots is ignored by checkpoint > >>> DETAIL: Some replication

Re: [HACKERS] Restricting maximum keep segments by repslots

2017-03-01 Thread Kyotaro HORIGUCHI
At Wed, 1 Mar 2017 08:06:10 -0800, Andres Freund wrote in <20170301160610.wc7ez3vihmial...@alap3.anarazel.de> > On 2017-02-28 12:42:32 +0900, Michael Paquier wrote: > > Please no. Replication slots are designed the current way because we > > don't want to have to use

Re: [HACKERS] PassDownLimitBound for ForeignScan/CustomScan [take-2]

2017-03-01 Thread Kouhei Kaigai
> Hello all, > > as this is my first mail to pgsql-hackers, please be gentle :) > Welcome to pgsql-hackers, > I've looked at the patch, and as I'm not that familiar with the pg-sourcecode, > customs and so on, this isn't a review, more like food for thought and all > should be taken with a grain

Re: [HACKERS] patch: function xmltable

2017-03-01 Thread Alvaro Herrera
I've been giving this a look. I started by tweaking the docs once again, and while verifying that the example works as expected, I replayed what I have in sgml: ... begin SGML paste ... For example, given the following XML document: the following query produces the result

Re: [HACKERS] [PATCH] Use $ parameters as replacement characters for pg_stat_statements

2017-03-01 Thread Lukas Fittl
On Wed, Mar 1, 2017 at 6:51 AM, Peter Eisentraut < peter.eisentr...@2ndquadrant.com> wrote: > > Hmm, I think this could confuse people into thinking that the queries > displayed were in fact prepared queries. > > Maybe we could gather some more ideas. > I think thats a reasonable concern - the

Re: [HACKERS] pg_dump, pg_dumpall and data durability

2017-03-01 Thread Michael Paquier
On Thu, Mar 2, 2017 at 2:26 AM, David Steele wrote: > This patch is in need of a committer. Any takers? > I didn't see a lot of enthusiasm from committers on the thread Stephen at least has showed interest. > so if nobody picks it up by the end of the CF I'm going to mark

Re: [HACKERS] timeouts in PostgresNode::psql

2017-03-01 Thread Craig Ringer
On 2 March 2017 at 03:19, Peter Eisentraut wrote: > On 2/26/17 21:28, Craig Ringer wrote: >> Amended patch attached after a few Perl-related comments I got on >> private mail. Instead of >> >> $exc_save !~ /^$timeout_exception.*/ >> >> I've updated to: >> >>

Re: [HACKERS] PATCH: two slab-like memory allocators

2017-03-01 Thread Andres Freund
On 2017-02-28 20:29:36 -0800, Andres Freund wrote: > On 2017-02-28 20:18:35 -0800, Andres Freund wrote: > > - Andres, hoping the buildfarm turns greener > > Oh well, that didn't work. Investigating. The fix for that was fairly trivial, and the buildfarm has cooled down. The issue was that on

Re: [HACKERS] logical decoding of two-phase transactions

2017-03-01 Thread Petr Jelinek
On 01/03/17 10:24, Craig Ringer wrote: > On 9 February 2017 at 21:23, Stas Kelvich wrote: > >>> On 2 Feb 2017, at 00:35, Craig Ringer wrote: >>> >>> Stas was concerned about what happens in logical decoding if we crash >>> between PREPSRE

Re: [HACKERS] mat views stats

2017-03-01 Thread Jim Mlodgenski
On Sun, Feb 26, 2017 at 11:49 AM, Robert Haas wrote: > On Wed, Feb 22, 2017 at 11:13 AM, Jim Nasby > wrote: > > Certainly easier, but I don't think it'd be better. Matviews really > aren't > > the same thing as tables. Off-hand (without reviewing

Re: [HACKERS] [BUGS] Seems bug in postgres_fdw?

2017-03-01 Thread Rader, David
On Mon, Feb 27, 2017 at 10:10 AM, Tom Lane wrote: > Sachin Kotwal writes: > > Here , Why postgresql takes different time when remote table and foreign > > table have different definition for timestamp column? > > I believe postgres_fdw sets the timezone

Re: [HACKERS] 2017-03 Commitfest In Progress

2017-03-01 Thread Thomas Munro
On Thu, Mar 2, 2017 at 4:42 AM, David Steele wrote: > The 2017-03 commitfest is now in progress. Here's the breakdown: > > Needs review: 128 > Waiting on Author: 26 > Ready for Committer: 26 > Total: 180 Not quite a record haul but close. -- Thomas Munro

Re: [HACKERS] ANALYZE command progress checker

2017-03-01 Thread Andres Freund
On March 1, 2017 11:34:48 AM PST, David Fetter wrote: >I notice that that commit has no SGML component. Should it have one? Don't think so. -- Sent from my Android device with K-9 Mail. Please excuse my brevity. -- Sent via pgsql-hackers mailing list

Re: [HACKERS] ANALYZE command progress checker

2017-03-01 Thread David Fetter
On Wed, Mar 01, 2017 at 10:28:23AM -0800, Andres Freund wrote: > On 2017-03-01 10:25:49 -0800, Andres Freund wrote: > > We now have a framework for this [1] (currently used by vacuum, but > > extensible). The question is about presentation. I'm fairly sure that > > we shouldn't just add yet

Re: [HACKERS] timeouts in PostgresNode::psql

2017-03-01 Thread Peter Eisentraut
On 2/26/17 21:28, Craig Ringer wrote: > Amended patch attached after a few Perl-related comments I got on > private mail. Instead of > > $exc_save !~ /^$timeout_exception.*/ > > I've updated to: > > $exc_save !~ /^\Q$timeout_exception\E/ > > i.e. don't do an unnecessary wildcard match at the

Re: [HACKERS] Logical replication existing data copy

2017-03-01 Thread Petr Jelinek
On 28/02/17 20:36, Erik Rijkers wrote: > This is the most frequent error that happens while doing pgbench-runs > over logical replication: I run it continuously all day, and every few > hours an error occurs of the kind seen below: a table (pgbench_history, > mostly) ends up 1 row short (673466

Re: [HACKERS] ANALYZE command progress checker

2017-03-01 Thread Andres Freund
On 2017-03-01 10:25:49 -0800, Andres Freund wrote: > We now have a framework for this [1] (currently used by vacuum, but > extensible). The question is about presentation. I'm fairly sure that > we shouldn't just add yet another framework, and I doubt that that's > what's proposed by Peter. > >

Re: [HACKERS] ANALYZE command progress checker

2017-03-01 Thread Andres Freund
On 2017-03-01 10:20:41 -0800, David Fetter wrote: > On Wed, Mar 01, 2017 at 09:45:40AM -0500, Peter Eisentraut wrote: > > On 2/28/17 04:24, vinayak wrote: > > > The view provides the information of analyze command progress details as > > > follows > > > postgres=# \d pg_stat_progress_analyze > >

Re: [HACKERS] ANALYZE command progress checker

2017-03-01 Thread David Fetter
On Wed, Mar 01, 2017 at 09:45:40AM -0500, Peter Eisentraut wrote: > On 2/28/17 04:24, vinayak wrote: > > The view provides the information of analyze command progress details as > > follows > > postgres=# \d pg_stat_progress_analyze > >View "pg_catalog.pg_stat_progress_analyze" > >

Re: [HACKERS] Possible spelling fixes

2017-03-01 Thread Andres Freund
On 2017-03-01 14:40:26 -0300, Alvaro Herrera wrote: > Josh Soref wrote: > > > One thing that would be helpful is if someone could comment on: > > https://github.com/jsoref/postgres/commit/9050882d601134ea1ba26f77ce5f1aaed75418de > > -#undef SH_ITERTOR > > +#undef SH_ITERATOR > > > > It's unclear

Re: [HACKERS] PassDownLimitBound for ForeignScan/CustomScan [take-2]

2017-03-01 Thread Tels
Hello all, as this is my first mail to pgsql-hackers, please be gentle :) I've looked at the patch, and as I'm not that familiar with the pg-sourcecode, customs and so on, this isn't a review, more like food for thought and all should be taken with a grain of salt. :) So here are a few

Re: [HACKERS] \if, \elseif, \else, \endif (was Re: PSQL commands: \quit_if, \quit_unless)

2017-03-01 Thread Corey Huinker
On Wed, Mar 1, 2017 at 12:23 PM, Fabien COELHO wrote: > > Hello Corey, > > on elif >> if misplaced elif >> misplaced elif error >> else >> eval expression >> => possible eval error >> set new status if eval fine >> > > Currently it is really: > > switch

Re: [HACKERS] Patch: Optimize memory allocation in function 'bringetbitmap'

2017-03-01 Thread Alvaro Herrera
Alvaro Herrera wrote: > Jinyu Zhang wrote: > > > Update the patch_brin_optimze_mem according to your comment. > > I have added this patch to the commitfest, which I've been intending to > get in for a long time. I'll be submitting an updated patch soon. Here it is. I addressed some of Tomas'

Re: [HACKERS] Possible spelling fixes

2017-03-01 Thread Alvaro Herrera
Josh Soref wrote: > One thing that would be helpful is if someone could comment on: > https://github.com/jsoref/postgres/commit/9050882d601134ea1ba26f77ce5f1aaed75418de > -#undef SH_ITERTOR > +#undef SH_ITERATOR > > It's unclear to me what that line is/was doing. It's possible that it > could be

Re: [HACKERS] SQL/JSON in PostgreSQL

2017-03-01 Thread Pavel Stehule
> > > >1. > >Added explicit casts bytea=>jsonb and jsonb=>bytea (for jsonb=>bytea >output using RETURNING bytea FORMAT JSONB and corresponding bytea=>jsonb >input using FORMAT JSONB). > > This point has sense in Oracle, where JSON is blob. But it is little bit obscure in

Re: [HACKERS] pg_dump, pg_dumpall and data durability

2017-03-01 Thread David Steele
On 1/22/17 11:02 PM, Michael Paquier wrote: > On Tue, Nov 29, 2016 at 1:30 PM, Michael Paquier > wrote: >> On Mon, Nov 14, 2016 at 6:07 PM, Michael Paquier >> wrote: >>> On Mon, Nov 14, 2016 at 6:04 PM, Albe Laurenz

Re: [HACKERS] log_autovacuum_min_duration doesn't log VACUUMs

2017-03-01 Thread Jeff Janes
On Wed, Mar 1, 2017 at 6:43 AM, Peter Eisentraut < peter.eisentr...@2ndquadrant.com> wrote: > On 2/10/17 03:38, Simon Riggs wrote: > > I guess its fairly obvious in the title, but > > log_autovacuum_min_duration doesn't log VACUUMs only autovacuums. > > > > What isn't obvious is why that

Re: [HACKERS] objsubid vs subobjid

2017-03-01 Thread Peter Eisentraut
On 3/1/17 09:51, Alvaro Herrera wrote: > Peter Eisentraut wrote: >> On 2/22/17 19:35, Jim Nasby wrote: >>> pg_get_object_address() currently returns a field called subobjid, while >>> pg_depend calls that objsubid. I'm guessing that wasn't on purpose >>> (especially because internally the

Re: [HACKERS] \if, \elseif, \else, \endif (was Re: PSQL commands: \quit_if, \quit_unless)

2017-03-01 Thread Fabien COELHO
Hello Corey, on elif if misplaced elif misplaced elif error else eval expression => possible eval error set new status if eval fine Currently it is really: switch (state) { case NONE: case ELSE_TRUE: case ELSE_FALSE: success = false; show some error

Re: [HACKERS] Restricting maximum keep segments by repslots

2017-03-01 Thread Peter Eisentraut
On 2/27/17 23:27, Petr Jelinek wrote: >>> WARNING: restart LSN of replication slots is ignored by checkpoint >>> DETAIL: Some replication slots lose required WAL segnents to continue. > However this is dangerous as logical replication slot does not consider > it error when too old LSN is

Re: [HACKERS] Restricting maximum keep segments by repslots

2017-03-01 Thread Peter Eisentraut
On 2/27/17 22:27, Kyotaro HORIGUCHI wrote: > This patch adds a GUC to put a limit to the number of segments > that replication slots can keep. Please measure it in size, not in number of segments. -- Peter Eisentraut http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support,

Re: [HACKERS] Possible spelling fixes

2017-03-01 Thread Josh Soref
Peter Eisentraut wrote: > Yes, some of that was committed, and some comments were offered. If > there is more to do, please send a rebased patch set. Conflicting comments were offered. And Heikki requested I send along the remainder. Which I did. Only one of those patches would have been

Re: [HACKERS] many copies of atooid() and oid_cmp()

2017-03-01 Thread Peter Eisentraut
On 1/12/17 09:36, Tom Lane wrote: > Peter Eisentraut writes: >> On 1/11/17 11:25 PM, Tom Lane wrote: >>> +1 for the concept, but I'm a bit worried about putting atooid() in >>> postgres_ext.h. That's going to impose on the namespace of libpq-using >>>

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

2017-03-01 Thread Masahiko Sawada
On Tue, Feb 28, 2017 at 10:42 PM, Pavan Deolasee wrote: > Hello All, > > During the second heap scan of CREATE INDEX CONCURRENTLY, we're only > interested in the tuples which were inserted after the first scan was > started. All such tuples can only exists in pages which

Re: [pgsql-www] [HACKERS] Small issue in online devel documentation build

2017-03-01 Thread Fabien COELHO
Hello Peter, I wrote a few lines of perl to move replaceable out of option and did some manual editing is special cases, the resulting simple 359 changes is attached. If the stylesheet produces unpleasant output, then the stylesheet should be changed. Sure. I'm not sure whether it is a

Re: [HACKERS] Possible spelling fixes

2017-03-01 Thread Josh Soref
I'll include it. -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

Re: [HACKERS] Possible spelling fixes

2017-03-01 Thread Josh Soref
I understood that they were git commits. I could have excluded the file but opted not to in case people were willing to take a small drift -- the SHAs are what someone needs to review the commit, and personally, I'd rather read something without typos than with -- especially in a summary. But,

Re: [HACKERS] Possible spelling fixes

2017-03-01 Thread Josh Soref
I can easily drop the shutdown* items; The reason for rowMarks is consistency with lr_arowMarks. I'll tentatively exclude that from any resubmission I make tonight... -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription:

Re: [HACKERS] \if, \elseif, \else, \endif (was Re: PSQL commands: \quit_if, \quit_unless)

2017-03-01 Thread Corey Huinker
On Wed, Mar 1, 2017 at 3:07 AM, Fabien COELHO wrote: > > Hello Corey, > > It doesn't strike me as much cleaner, but it's no worse, either. >> > > Hmmm. > > The "if (x) { x = ... ; if (x) {" does not help much to improve > readability and understandability... > > My 0.02€

Re: [HACKERS] Time to drop old-style (V0) functions?

2017-03-01 Thread Andres Freund
On 2017-03-01 11:18:34 -0500, Tom Lane wrote: > Andres Freund writes: > > On 2016-12-08 13:34:41 -0800, Andres Freund wrote: > >> Hi, > >> > >> I'm wondering if it's not time for $subject: > >> - V0 causes confusion / weird crashes when PG_FUNCTION_INFO_V1 was > >> forgotten

Re: [HACKERS] BRIN cost estimate

2017-03-01 Thread Alvaro Herrera
Alvaro Herrera wrote: > I have added this patch to the commitfest, which I've been intending to > get in for a long time. I'll be submitting an updated patch, if needed. Here is Emre's patch rebased to current sources. -- Álvaro Herrerahttps://www.2ndQuadrant.com/ PostgreSQL

Re: [HACKERS] objsubid vs subobjid

2017-03-01 Thread Alvaro Herrera
Peter Eisentraut wrote: > On 2/22/17 19:35, Jim Nasby wrote: > > pg_get_object_address() currently returns a field called subobjid, while > > pg_depend calls that objsubid. I'm guessing that wasn't on purpose > > (especially because internally the function uses objsubid), and it'd be > > nice

Re: [HACKERS] Possible spelling fixes

2017-03-01 Thread Alvaro Herrera
Josh Soref wrote: > >

Re: [HACKERS] Possible spelling fixes

2017-03-01 Thread Alvaro Herrera
Josh Soref wrote: > - else if (ControlFile->state == DB_SHUTDOWNING) > + else if (ControlFile->state == DB_SHUTTINGDOWN) SHUTDOWNING and SHUTDOWNED are typos first introduced by hacker emeritus Vadim Mikheev in 1999 together with WAL, commit 47937403676d. It goes to show that not every

Re: [HACKERS] WAL logging problem in 9.4.3?

2017-03-01 Thread David Steele
On 1/30/17 11:33 PM, Michael Paquier wrote: > On Fri, Dec 2, 2016 at 1:39 PM, Haribabu Kommi > wrote: >> The latest proposed patch still having problems. >> Closed in 2016-11 commitfest with "moved to next CF" status because of a bug >> fix patch. >> Please feel free to

Re: [HACKERS] perlcritic

2017-03-01 Thread Dagfinn Ilmari Mannsåker
Hi Peter, Peter Eisentraut writes: > I posted this about 18 months ago but then ran out of steam. [ ] Here > is an updated patch. The testing instructions below still apply. > Especially welcome would be ideas on how to address some of the places > I have

Re: [HACKERS] Time to drop old-style (V0) functions?

2017-03-01 Thread Tom Lane
Andres Freund writes: > On 2016-12-08 13:34:41 -0800, Andres Freund wrote: >> Hi, >> >> I'm wondering if it's not time for $subject: >> - V0 causes confusion / weird crashes when PG_FUNCTION_INFO_V1 was >> forgotten >> - They have us keep weird hacks around just for the sake

Re: [HACKERS] Restricting maximum keep segments by repslots

2017-03-01 Thread Andres Freund
Hi, On 2017-02-28 12:42:32 +0900, Michael Paquier wrote: > Please no. Replication slots are designed the current way because we > don't want to have to use something like wal_keep_segments as it is a > wart, and this applies as well for replication slots in my opinion. I think a per-slot option

Re: [HACKERS] Statement-level rollback

2017-03-01 Thread Tom Lane
Peter Eisentraut writes: > On 2/28/17 08:17, Tom Lane wrote: >> I do not really see how this would ever get past the compatibility >> problems that forced us to give up on server-side autocommit years ago. > I think it's different because it's not a global

Re: [HACKERS] some dblink refactoring

2017-03-01 Thread Peter Eisentraut
On 2/28/17 22:22, Corey Huinker wrote: > Any chance we can make get_connect_string() a core function or at least > externally accessible? [get_connect_string() gets the connection string for a foreign server] The connection string for a foreign server depends on the nature of the foreign server.

Re: [HACKERS] Possible spelling fixes

2017-03-01 Thread Peter Eisentraut
On 3/1/17 09:12, Josh Soref wrote: > On Mar 1, 2017 9:06 AM, "Peter Eisentraut" > > wrote: > > On 2/6/17 06:03, Heikki Linnakangas wrote: > > Ah, yes please. Post them over and I'll have a look at those as well.

Re: [HACKERS] New Committer - Andrew Gierth

2017-03-01 Thread Joe Conway
On 02/28/2017 10:22 AM, Stephen Frost wrote: > Greetings! > > The PostgreSQL committers would like to welcome Andrew Gierth as a new > committer for the PostgreSQL project. > > Andrew - welcome! Congratulations! Joe -- Crunchy Data - http://crunchydata.com PostgreSQL Support for Secure

Re: [HACKERS] Should we cacheline align PGXACT?

2017-03-01 Thread Ashutosh Sharma
On Wed, Mar 1, 2017 at 5:29 PM, Simon Riggs wrote: > > On 1 March 2017 at 04:50, Ashutosh Sharma wrote: >> >> On Tue, Feb 28, 2017 at 11:44 PM, Simon Riggs wrote: >>> >>> On 28 February 2017 at 11:34, Ashutosh Sharma

Re: [pgsql-www] [HACKERS] Small issue in online devel documentation build

2017-03-01 Thread Peter Eisentraut
On 2/19/17 12:34, Fabien COELHO wrote: > I wrote a few lines of perl to move replaceable out of option and did some > manual editing is special cases, the resulting simple 359 changes is > attached. If the stylesheet produces unpleasant output, then the stylesheet should be changed. The

[HACKERS] 2017-03 Commitfest In Progress

2017-03-01 Thread David Steele
The 2017-03 commitfest is now in progress. Here's the breakdown: Needs review: 128 Waiting on Author: 26 Ready for Committer: 26 Total: 180 If you are an author and have a patch in the "Waiting for Author" state please update it as soon as you can. Otherwise, jump in and start reviewing! --

Re: [HACKERS] Possible spelling fixes

2017-03-01 Thread David Rowley
On 6 February 2017 at 15:50, Josh Soref wrote: > It's now split more or less to your suggestion: > https://github.com/jsoref/postgres/commits/spelling - * Note that this algrithm is know to not be very effective (O(N^2)) + * Note that this algorithm is know to not be very

Re: [HACKERS] Statement-level rollback

2017-03-01 Thread Peter Eisentraut
On 2/28/17 02:39, Tsunakawa, Takayuki wrote: > I'd like to propose statement-level rollback feature. To repeat myself, this > is requested for users to migrate from other DBMSs to PostgreSQL. They > expect that a failure of one SQL statement should not abort the entire > transaction and their

Re: [HACKERS] Statement-level rollback

2017-03-01 Thread Peter Eisentraut
On 2/28/17 08:17, Tom Lane wrote: > I do not really see how this would ever get past the compatibility > problems that forced us to give up on server-side autocommit years ago. I think it's different because it's not a global setting, it's only a behavior you select explicitly when you start a

Re: [HACKERS] Time to drop old-style (V0) functions?

2017-03-01 Thread Peter Eisentraut
On 3/1/17 02:22, Andres Freund wrote: > One unaddressed question in those patches is what we do with > src/backend/utils/fmgr/README - I'm not quite sure what its purpose is, > in its current state. If we want to keep it, we'd probably have to > pretty aggressively revise it? Some of the

Re: [HACKERS] [PATCH] Use $ parameters as replacement characters for pg_stat_statements

2017-03-01 Thread Peter Eisentraut
On 2/28/17 20:01, Lukas Fittl wrote: > Currently pg_stat_statements replaces constant values with ? characters. > I've seen this be a problem on multiple occasions, in particular since > it conflicts with the use of ? as an operator. > > I'd like to propose changing the replacement character from

Re: [HACKERS] ANALYZE command progress checker

2017-03-01 Thread Peter Eisentraut
On 2/28/17 04:24, vinayak wrote: > The view provides the information of analyze command progress details as > follows > postgres=# \d pg_stat_progress_analyze >View "pg_catalog.pg_stat_progress_analyze" Hmm, do we want a separate "progress" system view for every kind of command?

Re: [HACKERS] log_autovacuum_min_duration doesn't log VACUUMs

2017-03-01 Thread Peter Eisentraut
On 2/10/17 03:38, Simon Riggs wrote: > I guess its fairly obvious in the title, but > log_autovacuum_min_duration doesn't log VACUUMs only autovacuums. > > What isn't obvious is why that restruction is useful. Because there are already various tools available to log activity of session

Re: [HACKERS] [POC] hash partitioning

2017-03-01 Thread Aleksander Alekseev
> We can achieve desired result through creating a separate partitioned table > and making the DETACH/ATTACH manipulation, though. But IMO it's not flexible > case. I think it would be great to allow end user to decide. If user is not interested in subpartitions he or she can use syntax like

  1   2   >