Re: [HACKERS] pgcrypto: PGP signatures

2014-08-22 Thread Marko Tiikkaja
On 8/22/14, 2:57 AM, Thomas Munro wrote: I took a quick look at your patch at http://www.postgresql.org/message-id/53edbcf0.9070...@joh.to (sorry I didn't reply directly as I didn't have the message). It applies cleanly, builds, and the tests pass. I will hopefully have more to say after I've

Re: [HACKERS] WIP Patch for GROUPING SETS phase 1

2014-08-22 Thread Andrew Gierth
Tom == Tom Lane t...@sss.pgh.pa.us writes: Tom Perhaps so. I would really prefer not to have to get into Tom estimating how many people will be inconvenienced how badly. Tom It's clear to me that not a lot of sweat has been put into Tom seeing if we can avoid reserving the keyword, and I

Re: [HACKERS] option -T in pg_basebackup doesn't work on windows

2014-08-22 Thread Heikki Linnakangas
On 08/22/2014 07:08 AM, Amit Kapila wrote: On Thu, Aug 21, 2014 at 3:44 PM, Amit Kapila amit.kapil...@gmail.com wrote: On Tue, Aug 19, 2014 at 9:51 AM, Amit Kapila amit.kapil...@gmail.com wrote: On Mon, Aug 18, 2014 at 7:50 PM, Heikki Linnakangas hlinnakan...@vmware.com wrote: Wouldn't it

[HACKERS] potential bug in psql

2014-08-22 Thread Szymon Guz
Hi, when I run `\s` in psql, I get the nice list of queries with an error at the end: \s could not save history to file /dev/tty: No such file or directory Newest ubuntu from trunk PostgreSQL 9.5devel on x86_64-unknown-linux-gnu, compiled by Ubuntu clang version 3.4-1ubuntu3

Re: [HACKERS] Proposal to add a QNX 6.5 port to PostgreSQL

2014-08-22 Thread Andres Freund
On 2014-08-22 01:36:37 -0400, Noah Misch wrote: On Thu, Aug 21, 2014 at 01:33:38AM +0200, Andres Freund wrote: On 2014-07-25 18:29:53 -0400, Tom Lane wrote: * QNX lacks sigaction SA_RESTART: I modified src/include/port.h to define macros to retry system calls upon EINTR

Re: [HACKERS] Removing dependency to wsock32.lib when compiling code on WIndows

2014-08-22 Thread Michael Paquier
On Fri, Aug 15, 2014 at 8:00 PM, Noah Misch n...@leadboat.com wrote: On Fri, Aug 15, 2014 at 12:49:36AM -0700, Michael Paquier wrote: Btw, how do you determine if MSVC is using HAVE_GETADDRINFO? Is it decided by the inclusion of getaddrinfo.c in @pgportfiles of Mkvdbuild.pm?

Re: [HACKERS] option -T in pg_basebackup doesn't work on windows

2014-08-22 Thread Amit Kapila
On Fri, Aug 22, 2014 at 1:00 PM, Heikki Linnakangas hlinnakan...@vmware.com wrote: On 08/22/2014 07:08 AM, Amit Kapila wrote: Today morning, I realised that there is one problem with the patch I sent yesterday and the problem is that incase user has not given -T option, it will not be able to

Re: [HACKERS] pg_upgrade: allow multiple -o/-O options

2014-08-22 Thread Pavel Raiskup
On Thursday 21 of August 2014 18:26:37 Bruce Momjian wrote: On Tue, Mar 4, 2014 at 04:52:56PM +0100, Pavel Raiskup wrote: RFE: Consider that you want to run pg_upgrade via some script with some default '-o' option. But then you also want to give the script's user a chance to specify the

Re: [HACKERS] Are postgresql-9.4 binaries available on Windows XP?

2014-08-22 Thread Dave Page
Hi On Fri, Aug 22, 2014 at 4:45 AM, Hiroshi Inoue in...@tpf.co.jp wrote: Hi Dave and Andrew, I recently noticed the thread [BUGS] BUG #11039: installation fails when trying to install C++ redistributable . Unfortunately I have no XP machine at hand and can't test the installer by

Re: [HACKERS] inherit support for foreign tables

2014-08-22 Thread Etsuro Fujita
(2014/08/22 12:58), Alvaro Herrera wrote: Noah Misch wrote: I'm anticipating a bug report along these lines: I saw poor estimates involving a child foreign table, so I ran ANALYZE VERBOSE, which reported 'INFO: analyzing public.parent inheritance tree'. Estimates remained poor, so

Re: [HACKERS] Support for N synchronous standby servers

2014-08-22 Thread Rajeev rastogi
On 09 August 2014 11:33, Michael Paquier Wrote: Please find attached a patch to add support of synchronous replication for multiple standby servers. This is controlled by the addition of a new GUC parameter called synchronous_standby_num, that makes server wait for transaction commit on the

Re: [HACKERS] Re: proposal: ignore null fields in not relation type composite type based constructors

2014-08-22 Thread Jeevan Chalke
Hi Pavel, You have said that XMLFOREST has something which ignores nulls, what's that? Will you please provide an example ? I am NOT sure, but here you are trying to omit entire field from the output when its value is NULL. But that will add an extra efforts at other end which is using output of

Re: [HACKERS] option -T in pg_basebackup doesn't work on windows

2014-08-22 Thread Heikki Linnakangas
On 08/22/2014 11:35 AM, Amit Kapila wrote: On Fri, Aug 22, 2014 at 1:00 PM, Heikki Linnakangas hlinnakan...@vmware.com wrote: On 08/22/2014 07:08 AM, Amit Kapila wrote: Today morning, I realised that there is one problem with the patch I sent yesterday and the problem is that incase user has

Re: [HACKERS] add line number as prompt option to psql

2014-08-22 Thread Jeevan Chalke
I would like to ignore this as UINTMAX lines are too much for a input buffer to hold. It is almost NIL chances to hit this. Yeah, most likely you will run out of memory before reaching that point, or out of patience. Yep. BTW, I have marked this as waiting for committer. Thanks --

Re: [HACKERS] WIP Patch for GROUPING SETS phase 1

2014-08-22 Thread Stephen Frost
* Andrew Gierth (and...@tao11.riddles.org.uk) wrote: Having now spent some more time looking, I believe there is a solution which makes it unreserved which does not require any significant pain in the code. I'm not entirely convinced that this is the right approach in the long term, but it

Re: [HACKERS] Proposal to add a QNX 6.5 port to PostgreSQL

2014-08-22 Thread Noah Misch
On Fri, Aug 22, 2014 at 09:34:42AM +0200, Andres Freund wrote: On 2014-08-22 01:36:37 -0400, Noah Misch wrote: On Thu, Aug 21, 2014 at 01:33:38AM +0200, Andres Freund wrote: On 2014-07-25 18:29:53 -0400, Tom Lane wrote: * QNX lacks sigaction SA_RESTART: I modified

Re: [HACKERS] pg_upgrade: allow multiple -o/-O options

2014-08-22 Thread Bruce Momjian
On Fri, Aug 22, 2014 at 10:52:12AM +0200, Pavel Raiskup wrote: On Thursday 21 of August 2014 18:26:37 Bruce Momjian wrote: On Tue, Mar 4, 2014 at 04:52:56PM +0100, Pavel Raiskup wrote: RFE: Consider that you want to run pg_upgrade via some script with some default '-o' option. But then

Re: [HACKERS] B-Tree support function number 3 (strxfrm() optimization)

2014-08-22 Thread Robert Haas
On Thu, Aug 14, 2014 at 1:24 PM, Peter Geoghegan p...@heroku.com wrote: On Thu, Aug 14, 2014 at 9:13 AM, Robert Haas robertmh...@gmail.com wrote: Committed that way. As the patch is by and large the same as what I submitted for this originally, I credited myself as first author and you as

Re: [HACKERS] Is this a bug?

2014-08-22 Thread Robert Haas
On Thu, Aug 21, 2014 at 7:17 PM, Bruce Momjian br...@momjian.us wrote: On Tue, Mar 18, 2014 at 09:11:46AM -0400, Robert Haas wrote: On Mon, Mar 17, 2014 at 10:27 PM, Michael Paquier michael.paqu...@gmail.com wrote: On Tue, Mar 18, 2014 at 10:24 AM, Fabrízio de Royes Mello

Re: [HACKERS] Proposal to add a QNX 6.5 port to PostgreSQL

2014-08-22 Thread Andres Freund
Hi, On 2014-08-21 15:25:44 +, Baker, Keith [OCDUS Non-JJ] wrote: About SA_RESTART: I would like to offer you a different perspective which may alter your current opinion. I believe the port.h QNX macro replacement for SA_RESTART is still a reasonable solution

Re: [HACKERS] After switching primary server while using replication slot.

2014-08-22 Thread Andres Freund
Hi, On 2014-08-20 13:14:30 -0400, Robert Haas wrote: On Tue, Aug 19, 2014 at 6:25 AM, Fujii Masao masao.fu...@gmail.com wrote: On Mon, Aug 18, 2014 at 11:16 PM, Sawada Masahiko sawada.m...@gmail.com wrote: Hi all, After switching primary serer while using repliaction slot, the standby

Re: [HACKERS] WIP Patch for GROUPING SETS phase 1

2014-08-22 Thread Alvaro Herrera
Andrew Gierth wrote: (This of course means that if someone has a cube() function call in a group by clause of a view, then upgrading will change the meaning of the view and possibly fail to create it; there seems to be no fix for this, not even using the latest pg_dump, since pg_dump relies

Re: [HACKERS] Proposal to add a QNX 6.5 port to PostgreSQL

2014-08-22 Thread Alvaro Herrera
Andres Freund wrote: Hi, On 2014-08-21 15:25:44 +, Baker, Keith [OCDUS Non-JJ] wrote: About SA_RESTART: I would like to offer you a different perspective which may alter your current opinion. I believe the port.h QNX macro replacement for SA_RESTART is

Re: [HACKERS] Support for N synchronous standby servers

2014-08-22 Thread Michael Paquier
On Fri, Aug 22, 2014 at 7:14 PM, Rajeev rastogi rajeev.rast...@huawei.com wrote: I have just started looking into this patch. Please find below my first level of observation from the patch: Thanks! Updated patch attached. 1. Allocation of memory for sync_nodes in function

Re: [HACKERS] delta relations in AFTER triggers

2014-08-22 Thread Kevin Grittner
Amit Khandekar amit.khande...@enterprisedb.com wrote: On 15 August 2014 04:04, Kevin Grittner kgri...@ymail.com wrote: The identifiers in the trigger function are not resolved to particular objects until there is a request to fire the trigger. Ah ok, you are talking about changes specific to

Re: [HACKERS] potential bug in psql

2014-08-22 Thread Tom Lane
Szymon Guz mabew...@gmail.com writes: when I run `\s` in psql, I get the nice list of queries with an error at the end: \s could not save history to file /dev/tty: No such file or directory Well, that's interesting ... what version of which readline library are you using? Presumably what is

Re: [HACKERS] Proposal to add a QNX 6.5 port to PostgreSQL

2014-08-22 Thread Baker, Keith [OCDUS Non-JJ]
I am reaching out to our QNX support contacts today, I will let you know how they respond. Keith Baker -Original Message- From: Alvaro Herrera [mailto:alvhe...@2ndquadrant.com] Sent: Friday, August 22, 2014 10:42 AM To: Andres Freund Cc: Baker, Keith [OCDUS Non-JJ]; Robert Haas;

Re: [HACKERS] potential bug in psql

2014-08-22 Thread Alvaro Herrera
Tom Lane wrote: TBH, though, \s doesn't seem to me to be anywhere near worth the amount of work we've already put into it, let alone a major new implementation effort. Who's for just removing the command altogether? I use it every once in a while. Is there a replacement? There are several

Re: [HACKERS] potential bug in psql

2014-08-22 Thread Szymon Guz
On 22 August 2014 17:06, Tom Lane t...@sss.pgh.pa.us wrote: Szymon Guz mabew...@gmail.com writes: when I run `\s` in psql, I get the nice list of queries with an error at the end: \s could not save history to file /dev/tty: No such file or directory Well, that's interesting ... what

Re: [HACKERS] Proposal to add a QNX 6.5 port to PostgreSQL

2014-08-22 Thread Andres Freund
On 2014-08-22 10:41:55 -0400, Alvaro Herrera wrote: Andres Freund wrote: Hi, On 2014-08-21 15:25:44 +, Baker, Keith [OCDUS Non-JJ] wrote: About SA_RESTART: I would like to offer you a different perspective which may alter your current opinion. I

Re: [HACKERS] WIP Patch for GROUPING SETS phase 1

2014-08-22 Thread Andrew Gierth
Alvaro == Alvaro Herrera alvhe...@2ndquadrant.com writes: (This of course means that if someone has a cube() function call in a group by clause of a view, then upgrading will change the meaning of the view and possibly fail to create it; there seems to be no fix for this, not even using

Re: [HACKERS] [v9.5] Custom Plan API

2014-08-22 Thread Robert Haas
On Thu, Jul 17, 2014 at 3:38 PM, Tom Lane t...@sss.pgh.pa.us wrote: Alvaro Herrera alvhe...@2ndquadrant.com writes: I haven't followed this at all, but I just skimmed over it and noticed the CustomPlanMarkPos thingy; apologies if this has been discussed before. It seems a bit odd to me; why

Re: [HACKERS] [PATCH] Incremental backup: add backup profile to base backup

2014-08-22 Thread Robert Haas
On Mon, Aug 18, 2014 at 4:55 PM, Heikki Linnakangas hlinnakan...@vmware.com wrote: You're not thinking evil enough ;-). Let's say that you have a table that stores bank transfers. You can do a bank transfer to pay a merchant, get the goods delivered to you, and then a second transfer to

Re: [HACKERS] [PATCH] Incremental backup: add backup profile to base backup

2014-08-22 Thread Robert Haas
On Wed, Aug 20, 2014 at 7:33 PM, Claudio Freire klaussfre...@gmail.com wrote: On Wed, Aug 20, 2014 at 8:24 PM, Bruce Momjian br...@momjian.us wrote: On Mon, Aug 18, 2014 at 04:05:07PM +0300, Heikki Linnakangas wrote: But more to the point, I thought the consensus was to use the highest LSN of

Re: [HACKERS] [v9.5] Custom Plan API

2014-08-22 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: I think the threshold question for this incarnation of the patch is whether we're happy with new DDL (viz, CREATE CUSTOM PLAN PROVIDER) as a way of installing new plan providers into the database. I tend to agree with your conclusion that that's a

Re: [HACKERS] change alter user to be a true alias for alter role

2014-08-22 Thread Jov
I make the v2 of the patch,use Tom's advice. But I can't make ROLE and USER in the keyword list,it is hard to solve the conflict,or rewrite many gram rules. the problem is : role_or_user : ROLE | USER; xx_keyword:...| ROLE|...|USER..; this two rules produce conflict.So in v2,I remove ROLE and

Re: [HACKERS] 9.5: Better memory accounting, towards memory-bounded HashAgg

2014-08-22 Thread Robert Haas
On Wed, Aug 20, 2014 at 2:11 AM, Jeff Davis pg...@j-davis.com wrote: I attached a patch that uses two uint32 fields so that it doesn't increase the size of MemoryContextData, and it tracks memory usage for all contexts. I was unable to detect any performance regression vs. master, but on my

Re: [HACKERS] Is this a bug?

2014-08-22 Thread Bruce Momjian
On Fri, Aug 22, 2014 at 10:27:02AM -0400, Robert Haas wrote: On Thu, Aug 21, 2014 at 7:17 PM, Bruce Momjian br...@momjian.us wrote: On Tue, Mar 18, 2014 at 09:11:46AM -0400, Robert Haas wrote: On Mon, Mar 17, 2014 at 10:27 PM, Michael Paquier michael.paqu...@gmail.com wrote: On Tue, Mar

Re: [HACKERS] WIP Patch for GROUPING SETS phase 1

2014-08-22 Thread Robert Haas
On Thu, Aug 21, 2014 at 2:13 PM, Tom Lane t...@sss.pgh.pa.us wrote: Andrew Gierth and...@tao11.riddles.org.uk writes: Tom == Tom Lane t...@sss.pgh.pa.us writes: Tom I wonder if you've tried hard enough to avoid reserving the keyword. GROUP BY cube(a,b) is currently legal syntax and means

Re: [HACKERS] WIP Patch for GROUPING SETS phase 1

2014-08-22 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: On Thu, Aug 21, 2014 at 2:13 PM, Tom Lane t...@sss.pgh.pa.us wrote: Well, if there are any extant applications that use that exact phrasing, they're going to be broken in any case. That does not mean that we have to break every other appearance of

Re: [HACKERS] 9.5: Better memory accounting, towards memory-bounded HashAgg

2014-08-22 Thread Tomas Vondra
On 20.8.2014 08:11, Jeff Davis wrote: On Tue, 2014-08-19 at 12:54 +0200, Tomas Vondra wrote: The use-case for this is tracking a chosen subtree of contexts - e.g. aggcontext and below, so I'd expect the tracked subtrees to be relatively shallow. Am I right? Right. My fear is that by

Re: [HACKERS] [GSoC2014] Patch ALTER TABLE ... SET LOGGED

2014-08-22 Thread Alvaro Herrera
Fabrízio de Royes Mello wrote: Em sexta-feira, 22 de agosto de 2014, Alvaro Herrera alvhe...@2ndquadrant.com escreveu: Fabrízio de Royes Mello wrote: I forgot to mention... I did again a lot of tests using different replication scenarios to make sure all is ok: - slaves async

Re: [HACKERS] Is this a bug?

2014-08-22 Thread Bruce Momjian
On Fri, Aug 22, 2014 at 12:53:30PM -0400, Bruce Momjian wrote: On Fri, Aug 22, 2014 at 10:27:02AM -0400, Robert Haas wrote: On Thu, Aug 21, 2014 at 7:17 PM, Bruce Momjian br...@momjian.us wrote: On Tue, Mar 18, 2014 at 09:11:46AM -0400, Robert Haas wrote: On Mon, Mar 17, 2014 at 10:27 PM,

Re: [HACKERS] [GSoC2014] Patch ALTER TABLE ... SET LOGGED

2014-08-22 Thread Fabrízio de Royes Mello
On Fri, Aug 22, 2014 at 3:32 PM, Alvaro Herrera alvhe...@2ndquadrant.com wrote: Fabrízio de Royes Mello wrote: Em sexta-feira, 22 de agosto de 2014, Alvaro Herrera alvhe...@2ndquadrant.com escreveu: Fabrízio de Royes Mello wrote: I forgot to mention... I did again a lot of tests

Re: [HACKERS] WIP Patch for GROUPING SETS phase 1

2014-08-22 Thread Greg Stark
On Fri, Aug 22, 2014 at 7:02 PM, Tom Lane t...@sss.pgh.pa.us wrote: So the proposal you are pushing is going to result in seriously teeing off some fraction of our userbase; and the argument why that would be acceptable seems to boil down to I think there are few enough of them that we don't

Re: [HACKERS] B-Tree support function number 3 (strxfrm() optimization)

2014-08-22 Thread Peter Geoghegan
On Fri, Aug 22, 2014 at 7:19 AM, Robert Haas robertmh...@gmail.com wrote: Patch 0002 no longer applies; please rebase. I attach rebased patch. Note that there is currently a bug in the master branch: + if (len2 = tss-buflen2) + { + pfree(tss-buf2); + tss-buflen1 = Max(len2 + 1,

Re: [HACKERS] WIP Patch for GROUPING SETS phase 1

2014-08-22 Thread Robert Haas
On Fri, Aug 22, 2014 at 2:02 PM, Tom Lane t...@sss.pgh.pa.us wrote: Robert Haas robertmh...@gmail.com writes: On Thu, Aug 21, 2014 at 2:13 PM, Tom Lane t...@sss.pgh.pa.us wrote: Well, if there are any extant applications that use that exact phrasing, they're going to be broken in any case.

Re: [HACKERS] Is this a bug?

2014-08-22 Thread Andres Freund
On August 22, 2014 8:33:57 PM CEST, Bruce Momjian br...@momjian.us wrote: On Fri, Aug 22, 2014 at 12:53:30PM -0400, Bruce Momjian wrote: On Fri, Aug 22, 2014 at 10:27:02AM -0400, Robert Haas wrote: On Thu, Aug 21, 2014 at 7:17 PM, Bruce Momjian br...@momjian.us wrote: On Tue, Mar 18, 2014 at

Re: [HACKERS] Is this a bug?

2014-08-22 Thread Robert Haas
On Fri, Aug 22, 2014 at 2:33 PM, Bruce Momjian br...@momjian.us wrote: Yes, you remember well. I will have to find a different way for pg_upgrade to call a no-op ALTER TABLE, which is fine. Looking at the ALTER TABLE options, I am going to put this check in a !IsBinaryUpgrade block so

Re: [HACKERS] [PATCH] Incremental backup: add backup profile to base backup

2014-08-22 Thread Bruce Momjian
On Fri, Aug 22, 2014 at 12:00:19PM -0400, Robert Haas wrote: On Wed, Aug 20, 2014 at 7:33 PM, Claudio Freire klaussfre...@gmail.com wrote: On Wed, Aug 20, 2014 at 8:24 PM, Bruce Momjian br...@momjian.us wrote: On Mon, Aug 18, 2014 at 04:05:07PM +0300, Heikki Linnakangas wrote: But more to

Re: [HACKERS] [GSoC2014] Patch ALTER TABLE ... SET LOGGED

2014-08-22 Thread Robert Haas
On Fri, Aug 22, 2014 at 2:32 PM, Alvaro Herrera alvhe...@2ndquadrant.com wrote: Fabrízio de Royes Mello wrote: Em sexta-feira, 22 de agosto de 2014, Alvaro Herrera alvhe...@2ndquadrant.com escreveu: Fabrízio de Royes Mello wrote: I forgot to mention... I did again a lot of tests using

Re: [HACKERS] 9.5: Better memory accounting, towards memory-bounded HashAgg

2014-08-22 Thread Robert Haas
On Fri, Aug 22, 2014 at 2:13 PM, Tomas Vondra t...@fuzzy.cz wrote: I don't think we really need to abandon the 'tracked' flag (or that we should). I think it was useful, and removing it might be one of the reasons why Robert now sees worse impact than before. The version that introduced that

Re: [HACKERS] SKIP LOCKED DATA (work in progress)

2014-08-22 Thread Alvaro Herrera
One thing I just noticed is that we uselessly set an error context callback when waiting in ConditionalMultiXactIdWait, which is pretty useless (because we don't actually wait there at all) -- we don't set one in ConditionalXactLockTableWait, which makes sense, but for some reason I failed to

Re: [HACKERS] [GSoC2014] Patch ALTER TABLE ... SET LOGGED

2014-08-22 Thread Fabrízio de Royes Mello
On Fri, Aug 22, 2014 at 4:22 PM, Robert Haas robertmh...@gmail.com wrote: On Fri, Aug 22, 2014 at 2:32 PM, Alvaro Herrera alvhe...@2ndquadrant.com wrote: Fabrízio de Royes Mello wrote: Em sexta-feira, 22 de agosto de 2014, Alvaro Herrera alvhe...@2ndquadrant.com escreveu: Fabrízio

Re: [HACKERS] [GSoC2014] Patch ALTER TABLE ... SET LOGGED

2014-08-22 Thread Alvaro Herrera
Robert Haas wrote: Hmm. I confess to not having paid enough attention to this, Sorry about that. I guess I should somehow flag threads I'm planning to commit this so that other people can review stuff carefully. but: 1. Loggedness is not a word. I think that persistence or

Re: [HACKERS] [GSoC2014] Patch ALTER TABLE ... SET LOGGED

2014-08-22 Thread Alvaro Herrera
Fabrízio de Royes Mello wrote: On Fri, Aug 22, 2014 at 4:22 PM, Robert Haas robertmh...@gmail.com wrote: 2. The patch seems to think that it can sometimes be safe to change the relpersistence of an existing relation. Unless you can be sure that no buffers can possibly be present in

Re: [HACKERS] [GSoC2014] Patch ALTER TABLE ... SET LOGGED

2014-08-22 Thread Fabrízio de Royes Mello
On Fri, Aug 22, 2014 at 4:45 PM, Alvaro Herrera alvhe...@2ndquadrant.com wrote: 2. The patch seems to think that it can sometimes be safe to change the relpersistence of an existing relation. Unless you can be sure that no buffers can possibly be present in shared_buffers and nobody will

Re: [HACKERS] [GSoC2014] Patch ALTER TABLE ... SET LOGGED

2014-08-22 Thread Alvaro Herrera
Fabrízio de Royes Mello wrote: On Fri, Aug 22, 2014 at 4:45 PM, Alvaro Herrera alvhe...@2ndquadrant.com wrote: I pointed out, in the email just before pushing the patch, that perhaps we should pass down the new relpersistence flag into finish_heap_swap, and from there we could pass it

Re: [HACKERS] [GSoC2014] Patch ALTER TABLE ... SET LOGGED

2014-08-22 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: 2. The patch seems to think that it can sometimes be safe to change the relpersistence of an existing relation. Unless you can be sure that no buffers can possibly be present in shared_buffers and nobody will use an existing relcache entry to read a

Re: [HACKERS] [GSoC2014] Patch ALTER TABLE ... SET LOGGED

2014-08-22 Thread Tom Lane
Alvaro Herrera alvhe...@2ndquadrant.com writes: Robert Haas wrote: 1. Loggedness is not a word. I think that persistence or relpersistence would be better. You want me to change that to chgPersistence and so on? No prob, just LMK. +1 for s/loggedness/persistence/ -- I agree with Robert

Re: [HACKERS] WIP Patch for GROUPING SETS phase 1

2014-08-22 Thread Andrew Dunstan
On 08/22/2014 02:42 PM, Greg Stark wrote: On Fri, Aug 22, 2014 at 7:02 PM, Tom Lane t...@sss.pgh.pa.us wrote: So the proposal you are pushing is going to result in seriously teeing off some fraction of our userbase; and the argument why that would be acceptable seems to boil down to I think

Re: [HACKERS] WIP Patch for GROUPING SETS phase 1

2014-08-22 Thread Merlin Moncure
On Fri, Aug 22, 2014 at 1:52 PM, Robert Haas robertmh...@gmail.com wrote: On Fri, Aug 22, 2014 at 2:02 PM, Tom Lane t...@sss.pgh.pa.us wrote: https://www.youtube.com/watch?v=MT2gzzbyWpw At around 8 minutes, he shows utilization statistics for cube at around 1% across their install base.

Re: [HACKERS] WIP Patch for GROUPING SETS phase 1

2014-08-22 Thread Stephen Frost
* Andrew Dunstan (and...@dunslane.net) wrote: On 08/22/2014 02:42 PM, Greg Stark wrote: On Fri, Aug 22, 2014 at 7:02 PM, Tom Lane t...@sss.pgh.pa.us wrote: So the proposal you are pushing is going to result in seriously teeing off some fraction of our userbase; and the argument why that

Re: [HACKERS] WIP Patch for GROUPING SETS phase 1

2014-08-22 Thread Greg Stark
On Fri, Aug 22, 2014 at 10:37 PM, Stephen Frost sfr...@snowman.net wrote: Agreed- and how many of those have *every extension available* loaded... Actually that was also in the talk.a few slides later. 0.7% -- greg -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To

Re: [HACKERS] WIP Patch for GROUPING SETS phase 1

2014-08-22 Thread Stephen Frost
* Greg Stark (st...@mit.edu) wrote: On Fri, Aug 22, 2014 at 10:37 PM, Stephen Frost sfr...@snowman.net wrote: Agreed- and how many of those have *every extension available* loaded... Actually that was also in the talk.a few slides later. 0.7% So, 0.3% install cube w/o installing *every*

Re: [HACKERS] SKIP LOCKED DATA (work in progress)

2014-08-22 Thread Alvaro Herrera
heap_lock_tuple() has the following comment on top: * In the failure cases, the routine fills *hufd with the tuple's t_ctid, * t_xmax (resolving a possible MultiXact, if necessary), and t_cmax * (the last only for HeapTupleSelfUpdated, since we * cannot obtain cmax from a combocid generated

Re: [HACKERS] WIP Patch for GROUPING SETS phase 1

2014-08-22 Thread Andrew Gierth
Tom == Tom Lane t...@sss.pgh.pa.us writes: Tom I'm not convinced of that; I think some creative hackery in the Tom grammar might be able to deal with this. Making GROUP BY CUBE(a,b) parse as grouping sets rather than as a function turned out to be the easy part: give CUBE a lower precedence

Re: [HACKERS] [GSoC2014] Patch ALTER TABLE ... SET LOGGED

2014-08-22 Thread Fabrízio de Royes Mello
On Fri, Aug 22, 2014 at 4:45 PM, Alvaro Herrera alvhe...@2ndquadrant.com wrote: BTW why is it that index_build() checks the heap's relpersistence flag rather than the index'? I'm curious about it too... the code in src/backend/catalog/index.c is: 1975 if

Re: [HACKERS] 9.5: Better memory accounting, towards memory-bounded HashAgg

2014-08-22 Thread Tomas Vondra
On 20.8.2014 08:11, Jeff Davis wrote: On Tue, 2014-08-19 at 12:54 +0200, Tomas Vondra wrote: It would be easier to resolve the performance concern if I could reliably get the results Robert is getting. I think I was able to reproduce the regression with the old patch, but the results were

Re: [HACKERS] [v9.5] Custom Plan API

2014-08-22 Thread Kohei KaiGai
2014-08-23 0:39 GMT+09:00 Robert Haas robertmh...@gmail.com: On Thu, Jul 17, 2014 at 3:38 PM, Tom Lane t...@sss.pgh.pa.us wrote: Alvaro Herrera alvhe...@2ndquadrant.com writes: I haven't followed this at all, but I just skimmed over it and noticed the CustomPlanMarkPos thingy; apologies if

Re: [HACKERS] Is this a bug?

2014-08-22 Thread Bruce Momjian
On Fri, Aug 22, 2014 at 03:12:47PM -0400, Robert Haas wrote: On Fri, Aug 22, 2014 at 2:33 PM, Bruce Momjian br...@momjian.us wrote: Yes, you remember well. I will have to find a different way for pg_upgrade to call a no-op ALTER TABLE, which is fine. Looking at the ALTER TABLE options, I

Re: [HACKERS] proposal: rounding up time value less than its unit.

2014-08-22 Thread Tomonari Katsumata
Thank you for the comments. It was a bug in my patch as another developer says. I've not considered about the value 'zero', sorry. I attached new patch. This patch rounds up the value when only it's less than required unit. Like below. (unit: min) 0-0 0s-0 10s-1 70s-1 Although my original

Re: [HACKERS] Re: proposal: ignore null fields in not relation type composite type based constructors

2014-08-22 Thread Pavel Stehule
Hello 2014-08-22 12:21 GMT+02:00 Jeevan Chalke jeevan.cha...@enterprisedb.com: Hi Pavel, You have said that XMLFOREST has something which ignores nulls, what's that? Will you please provide an example ? I was partially wrong - XMLFOREST ignore null always postgres=# select xmlforest(10

Re: [HACKERS] Support for N synchronous standby servers

2014-08-22 Thread Michael Paquier
On Fri, Aug 22, 2014 at 11:42 PM, Michael Paquier michael.paqu...@gmail.com wrote: 2. Logic of deciding the highest priority one seems to be in-correct. Assume, s_s_num = 3, s_s_names = 3,4,2,1 standby nodes are in order as: 1,2,3,4,5,6,7 As per the logic in patch,