Re: [HACKERS] Precedence of standard comparison operators

2015-03-12 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: On Tue, Mar 10, 2015 at 12:45 PM, David G. Johnston david.g.johns...@gmail.com wrote: I would vote for Auto meaning On in the .0 release. I don't think users will appreciate an auto value whose meaning might change at some point, and I doubt we've

Re: [HACKERS] proposal: disallow operator = and use it for named parameters

2015-03-12 Thread Kevin Grittner
Tom Lane t...@sss.pgh.pa.us wrote: Robert Haas robertmh...@gmail.com writes: On Tue, Mar 10, 2015 at 11:50 AM, Tom Lane t...@sss.pgh.pa.us wrote: Was there any consideration given to whether ruleutils should start printing NamedArgExprs with =? Or do we think that needs to wait? I have to

Re: [HACKERS] proposal: disallow operator = and use it for named parameters

2015-03-12 Thread Tom Lane
Kevin Grittner kgri...@ymail.com writes: Tom Lane t...@sss.pgh.pa.us wrote: Presumably we are going to change it at some point; maybe we should just do it rather than waiting another 5 years. +1 It has been deprecated long enough that I don't see the point of waiting. Uh, just to clarify,

Re: [HACKERS] Proposal : REINDEX xxx VERBOSE

2015-03-12 Thread Sawada Masahiko
On Tue, Mar 10, 2015 at 5:05 PM, Jim Nasby jim.na...@bluetreble.com wrote: On 3/9/15 9:43 PM, Sawada Masahiko wrote: On Fri, Mar 6, 2015 at 11:07 AM, Jim Nasby jim.na...@bluetreble.com wrote: On 3/2/15 10:58 AM, Sawada Masahiko wrote: On Wed, Feb 25, 2015 at 4:58 PM, Jim Nasby

Re: [HACKERS] Doing better at HINTing an appropriate column within errorMissingColumn()

2015-03-12 Thread Robert Haas
On Tue, Mar 10, 2015 at 4:03 PM, Peter Geoghegan p...@heroku.com wrote: On Tue, Mar 10, 2015 at 11:28 AM, Robert Haas robertmh...@gmail.com wrote: I'm prepared to commit this version if nobody finds a problem with it. It passes the additional regression tests you wrote. Looks good to me.

[HACKERS] timestamp format escape rules

2015-03-12 Thread Rikard Pavelic
Currently Postgres uses DATE WHITESPACE TIME for timestamp/tz datatype. Due whitespace it needs to be escaped when returned as record. How likely is to change WHITESPACE to something more ISO like, like 'T'? This would allow it to be serialized without the need for escaping. I'm asking this

Re: [HACKERS] EvalPlanQual behaves oddly for FDW queries involving system columns

2015-03-12 Thread Etsuro Fujita
On 2015/03/12 13:35, Tom Lane wrote: I don't like the execMain.c changes much at all. They look somewhat like they're intended to allow foreign tables to adopt a different locking strategy, I didn't intend such a thing. My intention is, foreign tables have markType = ROW_MARK_COPY as ever,

Re: [HACKERS] Install shared libs in lib/ and bin/ with MSVC (Was: install libpq.dll in bin directory on Windows / Cygwin)

2015-03-12 Thread Asif Naeem
Thank you Michael overall v3 patch looks good to me, There is one observation that it is not installing following lib files that are required for dev work i.e. inst\lib\libpq.lib inst\lib\libpgtypes.lib inst\lib\libecpg_compat.lib inst\lib\libecpg.lib Please do let me know if I missed

Re: [HACKERS] Turning off HOT/Cleanup sometimes

2015-03-12 Thread Andres Freund
On 2015-03-11 20:55:18 -0400, Peter Eisentraut wrote: I don't think so. Andres basically wanted a nontrival algorithm to determine how much pruning to do during a read-only scan. And Robert basically said, that's not really possible. I don't think either of us made really strong statements.

Re: [HACKERS] One question about security label command

2015-03-12 Thread Robert Haas
On Tue, Mar 10, 2015 at 6:58 PM, Kohei KaiGai kai...@kaigai.gr.jp wrote: ERRCODE_FEATURE_NOT_SUPPORTED is suitable error code here. Please see the attached one. Committed. I did not bother back-patching this, but I can do that if people think it's important. The sepgsql regression tests don't

[HACKERS] shebang for tcl postgresql modules

2015-03-12 Thread Jozef Mlich
Dear hackers, I would like to ask you if is there any reason to pretend tcl scripts are shell scripts? I am speaking namely about these files http://git.postgresql.org/gitweb/?p=postgresql.git;a=blob_plain;f=src/pl/tcl/modules/pltcl_delmod.in;hb=HEAD

Re: [HACKERS] How about to have relnamespace and relrole?

2015-03-12 Thread Jeevan Chalke
The following review has been posted through the commitfest application: make installcheck-world: tested, passed Implements feature: tested, passed Spec compliant: tested, passed Documentation:tested, passed Looks good. Passing it to committer. The new status of this

Re: [HACKERS] Parallel Seq Scan

2015-03-12 Thread Amit Langote
On 10-03-2015 PM 01:09, Amit Kapila wrote: On Tue, Mar 10, 2015 at 6:50 AM, Haribabu Kommi kommi.harib...@gmail.com Is this patch handles the cases where the re-scan starts without finishing the earlier scan? Do you mean to say cases like ANTI, SEMI Join (in nodeNestLoop.c) where we scan

[HACKERS] OOM-killer issue when updating a inheritance table which has large number of child tables

2015-03-12 Thread chenhj
Hi In my test(PG9.3.4), i found when update a parent table which has a large number of child tables, the execute plan will consume lots of memory. And possibly cause OOM. For example: create table maintb(id int,name char(10)); create table childtb_1 (CHECK ( id BETWEEN 1 AND 200))

Re: [HACKERS] Precedence of standard comparison operators

2015-03-12 Thread Greg Stark
On Wed, Mar 11, 2015 at 8:36 PM, Kevin Grittner kgri...@ymail.com wrote: Right; and they may have millions of lines of code which have been carefully tested and in production for years, and which may suddenly start to generate incorrect results on queries *or mangle existing data* with the

Re: [HACKERS] alter user/role CURRENT_USER

2015-03-12 Thread Kyotaro HORIGUCHI
Thank you for completing this and very sorry not to respond these days. I understood that it is committed after I noticed that rebasing my code failed.. Although after committed, I found some issues as I looked on it. Please forgive me to comment it now after all this time. Several changes in

Re: [HACKERS] OOM-killer issue when updating a inheritance table which has large number of child tables

2015-03-12 Thread David Fetter
On Thu, Mar 12, 2015 at 06:55:48PM +0800, chenhj wrote: Hi In my test(PG9.3.4), i found when update a parent table which has a large number of child tables, the execute plan will consume lots of memory. And possibly cause OOM. At the moment, partitioning into thousands of tables is not

Re: [HACKERS] logical column ordering

2015-03-12 Thread Andres Freund
Hi, On 2015-03-11 22:16:52 -0400, Tom Lane wrote: I agree though that it's worth considering defining pg_attribute.attnum as the logical column position so as to minimize the effects on client-side code. I actually wonder if it'd not make more sense to define it as the physical column number.

Re: [HACKERS] pg_dump: CREATE TABLE + CREATE RULE vs. relreplident

2015-03-12 Thread Andres Freund
Hi, On 2015-03-12 14:25:24 +0100, Marko Tiikkaja wrote: My colleague Per Lejontand brought to my attention that when dumping views with circular dependencies from a postgres version older than 9.4 using a recent pg_dump, the SQL looks something like the following: create table qwr();

Re: [HACKERS] logical column ordering

2015-03-12 Thread Alvaro Herrera
Tomas Vondra wrote: On 12.3.2015 03:16, Tom Lane wrote: I agree though that it's worth considering defining pg_attribute.attnum as the logical column position so as to minimize the effects on client-side code. I doubt there is much stuff client-side that cares about column creation

Re: [HACKERS] pg_dump: CREATE TABLE + CREATE RULE vs. relreplident

2015-03-12 Thread Andrew Gierth
Marko == Marko Tiikkaja ma...@joh.to writes: Marko Hi, Marko My colleague Per Lejontand brought to my attention that when Marko dumping views with circular dependencies from a postgres version Marko older than 9.4 using a recent pg_dump, the SQL looks something Marko like the following:

Re: [HACKERS] OOM-killer issue when updating a inheritance table which has large number of child tables

2015-03-12 Thread Tom Lane
chenhj chjis...@163.com writes: In my test(PG9.3.4), i found when update a parent table which has a large number of child tables, the execute plan will consume lots of memory. And possibly cause OOM. See

Re: [HACKERS] pg_dump: CREATE TABLE + CREATE RULE vs. relreplident

2015-03-12 Thread Tom Lane
Andrew Gierth and...@tao11.riddles.org.uk writes: Marko == Marko Tiikkaja ma...@joh.to writes: Marko create table qwr(); Marko create rule _RETURN as on select to qwr do instead select; I've wondered for a while whether this wouldn't have been better handled as: create view

Re: [HACKERS] logical column ordering

2015-03-12 Thread Tom Lane
Alvaro Herrera alvhe...@2ndquadrant.com writes: However, there's a difference between making a query silently given different results, and breaking it completely forcing the user to re-study how to write it. I think the latter is better. In that light we should just drop attnum as a column

[HACKERS] recovery_target_action doesn't work for anything but shutdown

2015-03-12 Thread Andres Freund
Hi, Unless I'm missing something recovery_target_action = promote/pause don't work. There's the following block of code in readRecoveryCommandFile(): /* * Override any inconsistent requests. Not that this is a change * of behaviour in 9.5; prior to this we simply

Re: [HACKERS] recovery_target_action doesn't work for anything but shutdown

2015-03-12 Thread Andres Freund
On 2015-03-12 15:52:02 +0100, Andres Freund wrote: I guess what you actually intended to test was StandbyModeRequested? Err, EnableHotStandby. Greetings, Andres Freund -- Andres Freund http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training Services

Re: [HACKERS] logical column ordering

2015-03-12 Thread Tomas Vondra
On 12.3.2015 14:17, Alvaro Herrera wrote: Tomas Vondra wrote: On 12.3.2015 03:16, Tom Lane wrote: I agree though that it's worth considering defining pg_attribute.attnum as the logical column position so as to minimize the effects on client-side code. I doubt there is much stuff

[HACKERS] pg_dump: CREATE TABLE + CREATE RULE vs. relreplident

2015-03-12 Thread Marko Tiikkaja
Hi, My colleague Per Lejontand brought to my attention that when dumping views with circular dependencies from a postgres version older than 9.4 using a recent pg_dump, the SQL looks something like the following: create table qwr(); create rule _RETURN as on select to qwr do instead

Re: [HACKERS] Install shared libs in lib/ and bin/ with MSVC (Was: install libpq.dll in bin directory on Windows / Cygwin)

2015-03-12 Thread Michael Paquier
On Wed, Mar 11, 2015 at 10:03 PM, Asif Naeem anaeem...@gmail.com wrote: Thank you Michael overall v3 patch looks good to me, There is one observation that it is not installing following lib files that are required for dev work i.e. Thanks for your input. inst\lib\libpq.lib

Re: [HACKERS] logical column ordering

2015-03-12 Thread Alvaro Herrera
Tomas Vondra wrote: On 12.3.2015 14:17, Alvaro Herrera wrote: Tomas Vondra wrote: On 12.3.2015 03:16, Tom Lane wrote: I agree though that it's worth considering defining pg_attribute.attnum as the logical column position so as to minimize the effects on client-side code. I doubt

Re: [HACKERS] shebang for tcl postgresql modules

2015-03-12 Thread Tom Lane
Jozef Mlich jml...@redhat.com writes: I would like to ask you if is there any reason to pretend tcl scripts are shell scripts? That is the time-honored standard formatting for tcl scripts, see for example page 2 here: http://www.tcl.tk/doc/styleGuide.pdf While we might get away with ignoring

Re: [HACKERS] Parallel Seq Scan

2015-03-12 Thread Amit Kapila
On Thu, Mar 12, 2015 at 8:33 PM, Thom Brown t...@linux.com wrote: On 12 March 2015 at 14:46, Amit Kapila amit.kapil...@gmail.com wrote: One additional change (we need to SetLatch() in HandleParallelMessageInterrupt) is done to handle the hang issue reported on parallel-mode thread.

Re: [HACKERS] assessing parallel-safety

2015-03-12 Thread Robert Haas
[ deferring responses to some points until a later time ] On Thu, Feb 19, 2015 at 1:19 AM, Noah Misch n...@leadboat.com wrote: This seems backwards to me. If some hypothetical selectivity estimator were PROPARALLEL_UNSAFE, then any operator that uses that function would also need to be

Re: [HACKERS] EvalPlanQual behaves oddly for FDW queries involving system columns

2015-03-12 Thread Tom Lane
Etsuro Fujita fujita.ets...@lab.ntt.co.jp writes: On 2015/03/12 13:35, Tom Lane wrote: I don't like the execMain.c changes much at all. They look somewhat like they're intended to allow foreign tables to adopt a different locking strategy, I didn't intend such a thing. My intention is,

Re: [HACKERS] Parallel Seq Scan

2015-03-12 Thread Thom Brown
On 12 March 2015 at 14:46, Amit Kapila amit.kapil...@gmail.com wrote: One additional change (we need to SetLatch() in HandleParallelMessageInterrupt) is done to handle the hang issue reported on parallel-mode thread. Without this change it is difficult to verify the patch (will remove this

Re: [HACKERS] pg_dump: CREATE TABLE + CREATE RULE vs. relreplident

2015-03-12 Thread Alvaro Herrera
Andrew Gierth wrote: Tom == Tom Lane t...@sss.pgh.pa.us writes: Tom Yeah, possibly. The existing pg_dump coding dates from before we Tom had CREATE OR REPLACE VIEW. As it happens it does not; the issue came up originally because of a hack I came up with, and I've never used any pg

[HACKERS] pg_xlog_replay_resume() considered armed and dangerous

2015-03-12 Thread Andres Freund
Hi, I think it's quite confusing that a function named pg_xlog_replay_resume() can cause a node to be promoted. That this is happened is kind of documented in the recovery.conf section of the manual: The intended use of the pause setting is to allow queries to be executed against the database to

Re: [HACKERS] pg_dump: CREATE TABLE + CREATE RULE vs. relreplident

2015-03-12 Thread Andrew Gierth
Tom == Tom Lane t...@sss.pgh.pa.us writes: I've wondered for a while whether this wouldn't have been better handled as: create view qwr(colnames...) as select null::type1, null::type2, ...; /* ... */ create or replace view qwr as ...; Tom Yeah, possibly. The existing pg_dump coding

Re: [HACKERS] Parallel Seq Scan

2015-03-12 Thread Thom Brown
On 12 March 2015 at 15:29, Amit Kapila amit.kapil...@gmail.com wrote: On Thu, Mar 12, 2015 at 8:33 PM, Thom Brown t...@linux.com wrote: On 12 March 2015 at 14:46, Amit Kapila amit.kapil...@gmail.com wrote: One additional change (we need to SetLatch() in HandleParallelMessageInterrupt) is

Re: [HACKERS] pg_dump: CREATE TABLE + CREATE RULE vs. relreplident

2015-03-12 Thread Robert Haas
On Thu, Mar 12, 2015 at 12:46 PM, Tom Lane t...@sss.pgh.pa.us wrote: As it happens it does not; the issue came up originally because of a hack I came up with, and I've never used any pg version so old it didn't have CREATE OR REPLACE VIEW. Nor does it look like the change was ever backpatched

Re: [HACKERS] pg_dump: CREATE TABLE + CREATE RULE vs. relreplident

2015-03-12 Thread Tom Lane
Andrew Gierth and...@tao11.riddles.org.uk writes: Tom == Tom Lane t...@sss.pgh.pa.us writes: Tom Yeah, possibly. The existing pg_dump coding dates from before we Tom had CREATE OR REPLACE VIEW. As it happens it does not; the issue came up originally because of a hack I came up with, and

Re: [HACKERS] pg_dump: CREATE TABLE + CREATE RULE vs. relreplident

2015-03-12 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: On Thu, Mar 12, 2015 at 12:46 PM, Tom Lane t...@sss.pgh.pa.us wrote: Sorry, that's mere historical revisionism. Can we please keep this a little more civil? Saying it that way implies bad faith. You could instead write I think you are mistaken.

Re: [HACKERS] Cube extension kNN support

2015-03-12 Thread Stas Kelvich
Documentation along with style fix. distances2r3.patch Description: Binary data On 08 Feb 2015, at 00:32, Alexander Korotkov aekorot...@gmail.com wrote: Hi! On Sat, Feb 7, 2015 at 12:45 PM, Stas Kelvich stas.kelv...@gmail.com wrote: I had updated old patch with kNN operators for cube

Re: [HACKERS] Parallel Seq Scan

2015-03-12 Thread Thom Brown
On 12 March 2015 at 16:20, Thom Brown t...@linux.com wrote: On 12 March 2015 at 15:29, Amit Kapila amit.kapil...@gmail.com wrote: On Thu, Mar 12, 2015 at 8:33 PM, Thom Brown t...@linux.com wrote: On 12 March 2015 at 14:46, Amit Kapila amit.kapil...@gmail.com wrote: One additional change (we

Re: [HACKERS] Documentation of bt_page_items()'s ctid field

2015-03-12 Thread Tom Lane
Jeff Janes jeff.ja...@gmail.com writes: I think we do want this. It was asked how much we want to include internals of the btree code into pageinspect documentation, but I think the nature of pageinspect makes that unavoidable. Yeah. Committed with a little bit of additional wordsmithing.

Re: [HACKERS] get_object_address support for additional object types

2015-03-12 Thread Alvaro Herrera
Stephen Frost wrote: I thought the rest of it looked alright. I agree it's a bit odd how the opfamily is handled but I agree with your assessment that there's not much better we can do with this object representation. Actually, on second thought I revisited this and changed the

Re: Custom/Foreign-Join-APIs (Re: [HACKERS] [v9.5] Custom Plan API)

2015-03-12 Thread Robert Haas
On Mon, Mar 9, 2015 at 11:18 PM, Kouhei Kaigai kai...@ak.jp.nec.com wrote: The attached patch integrates a suggestion from Ashutosh Bapat. It allows to track set of relations involved in a join, but replaced by foreign-/custom-scan. It enables to make correct EXPLAIN output, if FDW/CSP driver

Re: [HACKERS] forward vs backward slashes in msvc build code

2015-03-12 Thread Alvaro Herrera
Peter Eisentraut wrote: On 3/4/15 11:00 PM, Andrew Dunstan wrote: On 03/04/2015 10:37 PM, Peter Eisentraut wrote: I can't tell from just looking at the code how chkpass would normally find crypt. The msvc tools neither parse SHLIB_LINK nor have hardcoded knowledge. Any idea?

Re: [HACKERS] Turning off HOT/Cleanup sometimes

2015-03-12 Thread Robert Haas
On Thu, Mar 12, 2015 at 3:48 PM, Peter Eisentraut pete...@gmx.net wrote: On 3/12/15 5:41 AM, Andres Freund wrote: On 2015-03-11 20:55:18 -0400, Peter Eisentraut wrote: I don't think so. Andres basically wanted a nontrival algorithm to determine how much pruning to do during a read-only scan.

Re: [HACKERS] Reduce pinning in btree indexes

2015-03-12 Thread Kevin Grittner
Kevin Grittner kgri...@ymail.com wrote: Because these changes are just to a comment and a README file, I'm posting a patch-on-patch v3a (to be applied on top of v3). Here is some additional comment work that I hope will make things easier to understand for whoever next visits this code. There

Re: Custom/Foreign-Join-APIs (Re: [HACKERS] [v9.5] Custom Plan API)

2015-03-12 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: I took a look at this patch today and noticed that it incorporates not only documentation for the new functionality it adds, but also for the custom-scan functionality whose documentation I previously excluded from commit on the grounds that it needed

Re: [HACKERS] OOM-killer issue when updating a inheritance table which has large number of child tables

2015-03-12 Thread Stephen Frost
* Tom Lane (t...@sss.pgh.pa.us) wrote: chenhj chjis...@163.com writes: In my test(PG9.3.4), i found when update a parent table which has a large number of child tables, the execute plan will consume lots of memory. And possibly cause OOM. See

Re: [HACKERS] pg_rewind in contrib

2015-03-12 Thread Heikki Linnakangas
On 03/12/2015 08:49 AM, Amit Kapila wrote: With attached modified script, I am able to reproduce the error (I have used the latest pg_rewind patch (pg_rewind-bin-8)) Thanks! That reproduced the error for me too. Not sure why I couldn't reproduce it earlier. The cause was a silly typo in

Re: [HACKERS] logical column ordering

2015-03-12 Thread Peter Eisentraut
On 3/12/15 10:07 AM, Andres Freund wrote: I actually wonder if it'd not make more sense to define it as the physical column number. That'd reduce the invasiveness and risk of the patch considerably. Clearly, the number of places where attnum has to be changed to something else is not zero, and

Re: [HACKERS] logical column ordering

2015-03-12 Thread Peter Eisentraut
On 3/11/15 10:16 PM, Tom Lane wrote: I think using an OID would break more stuff than it fixes in dependency tracking; in particular you would now need an explicit dependency link from each column to its table, because the sub-object knowledge would no longer work. That might not be a bad

Re: [HACKERS] forward vs backward slashes in msvc build code

2015-03-12 Thread Peter Eisentraut
On 3/4/15 11:00 PM, Andrew Dunstan wrote: On 03/04/2015 10:37 PM, Peter Eisentraut wrote: On 2/15/15 6:55 AM, Michael Paquier wrote: I tested quickly the second patch with MS 2010 and I am getting a build failure: chkpass cannot complete because of crypt missing. On master build passes.

Re: [HACKERS] OOM-killer issue when updating a inheritance table which has large number of child tables

2015-03-12 Thread Tom Lane
Stephen Frost sfr...@snowman.net writes: * Tom Lane (t...@sss.pgh.pa.us) wrote: See file:///net/sss1/home/postgres/pgsql/doc/src/sgml/html/ddl-partitioning.html#DDL-PARTITIONING-CAVEATS Or perhaps, if you're on the Internet, this instead:

Re: [HACKERS] Turning off HOT/Cleanup sometimes

2015-03-12 Thread Peter Eisentraut
On 3/12/15 5:41 AM, Andres Freund wrote: On 2015-03-11 20:55:18 -0400, Peter Eisentraut wrote: I don't think so. Andres basically wanted a nontrival algorithm to determine how much pruning to do during a read-only scan. And Robert basically said, that's not really possible. I don't think

Re: [HACKERS] logical column ordering

2015-03-12 Thread Tomas Vondra
On 12.3.2015 03:16, Tom Lane wrote: Peter Eisentraut pete...@gmx.net writes: Side idea: Let attnum be the logical number, introduce attphysnum as the storage position, and add an oid to pg_attribute as the eternal identifier. That way you avoid breaking pretty much all user code that

Re: Custom/Foreign-Join-APIs (Re: [HACKERS] [v9.5] Custom Plan API)

2015-03-12 Thread Thom Brown
On 12 March 2015 at 21:28, Tom Lane t...@sss.pgh.pa.us wrote: Robert Haas robertmh...@gmail.com writes: I took a look at this patch today and noticed that it incorporates not only documentation for the new functionality it adds, but also for the custom-scan functionality whose documentation I

Re: [HACKERS] Bug in point releases 9.3.6 and 9.2.10?

2015-03-12 Thread Andres Freund
Hi, On 2015-03-12 16:42:24 -0700, Peter Geoghegan wrote: We want to create a new role when this happens, for various reasons. This occurs after recovery ends, but before the database has been unfenced. The template code that generates various ALTER ROLE statements in our internal provisioning

Re: [HACKERS] Bug in point releases 9.3.6 and 9.2.10?

2015-03-12 Thread Peter Geoghegan
In a hurry right now, so unfortunately I'll need to be brief for now. On Thu, Mar 12, 2015 at 5:21 PM, Andres Freund and...@2ndquadrant.com wrote: On 2015-03-12 16:42:24 -0700, Peter Geoghegan wrote: We want to create a new role when this happens, for various reasons. This occurs after

Re: [HACKERS] Bug in point releases 9.3.6 and 9.2.10?

2015-03-12 Thread Andres Freund
On 2015-03-12 17:42:33 -0700, Peter Geoghegan wrote: On Thu, Mar 12, 2015 at 5:21 PM, Andres Freund and...@2ndquadrant.com wrote: On 2015-03-12 16:42:24 -0700, Peter Geoghegan wrote: We want to create a new role when this happens, for various reasons. This occurs after recovery ends, but

Re: [HACKERS] Bug in point releases 9.3.6 and 9.2.10?

2015-03-12 Thread Peter Geoghegan
On Thu, Mar 12, 2015 at 5:56 PM, Andres Freund and...@2ndquadrant.com wrote: So, no hot standby enabled? Right. There've been some issues with seek(END) sometimes returning the wrong length in the past. And I've seen a report that might indicate a similar bug has been reintroduced. That

Re: [HACKERS] Reduce pinning in btree indexes

2015-03-12 Thread Peter Geoghegan
On Sat, Feb 14, 2015 at 4:19 PM, Kevin Grittner kgri...@ymail.com wrote: At some point we could consider building on this patch to recheck index conditions for heap access when a non-MVCC snapshot is used, check the visibility map for referenced heap pages when the TIDs are read for an

[HACKERS] Moving Pivotal's Greenplum work upstream

2015-03-12 Thread Ewan Higgs
Hi all,There has been some press regarding Pivotal's intent to release Greenplum source as part of an Open Development Platform (along with some of their Hadoop projects). Can anyone speak on whether any of Greenplum might find its way upstream? For example, if(!) the work is being released

Re: [HACKERS] Moving Pivotal's Greenplum work upstream

2015-03-12 Thread Josh Berkus
On 03/12/2015 03:24 PM, Ewan Higgs wrote: Hi all, There has been some press regarding Pivotal's intent to release Greenplum source as part of an Open Development Platform (along with some of their Hadoop projects). Can anyone speak on whether any of Greenplum might find its way upstream? For

Re: [HACKERS] proposal: searching in array function - array_position

2015-03-12 Thread Jim Nasby
On 3/11/15 1:19 AM, Pavel Stehule wrote: 2015-03-11 2:57 GMT+01:00 Robert Haas robertmh...@gmail.com mailto:robertmh...@gmail.com: On Tue, Mar 10, 2015 at 5:53 PM, Jim Nasby jim.na...@bluetreble.com mailto:jim.na...@bluetreble.com wrote: I don't think we need both array_offset and

Re: [HACKERS] [PATCH] Add transforms feature

2015-03-12 Thread Pavel Stehule
Hi I am looking to code. Some small issues: 1. fix missing semicolon pg_proc.h Oid protrftypes[1]; /* types for which to apply transforms */ 2. strange load lib by in sql scripts: DO '' LANGUAGE plperl; SELECT NULL::hstore; use load plperl; load hstore; instead 3.

Re: [HACKERS] Proposal : REINDEX xxx VERBOSE

2015-03-12 Thread Sawada Masahiko
On Thu, Mar 12, 2015 at 6:36 AM, Jim Nasby jim.na...@bluetreble.com wrote: On 3/11/15 6:33 AM, Sawada Masahiko wrote: As a refresher, current commands are: VACUUM (ANALYZE, VERBOSE) table1 (col1); REINDEX INDEX index1 FORCE; COPY table1 FROM 'file.txt' WITH (FORMAT csv);

Re: [HACKERS] Precedence of standard comparison operators

2015-03-12 Thread Peter Eisentraut
On 3/10/15 4:34 PM, Tom Lane wrote: There's one more reason, too: the code I have is designed to give correct warnings within the context of a parser that parses according to the spec-compliant rules. It's possible that a similar approach could be used to generate correct warnings within a

[HACKERS] Bug in point releases 9.3.6 and 9.2.10?

2015-03-12 Thread Peter Geoghegan
Heroku Postgres runs provisioning code that performs certain actions on roles when creating a new fork of an existing database. This often causes the new fork to be on the latest point release, where the database being forked was not. We want to create a new role when this happens, for various

Re: [HACKERS] pg_rewind in contrib

2015-03-12 Thread Amit Kapila
On Wed, Mar 11, 2015 at 2:23 PM, Heikki Linnakangas hlinn...@iki.fi wrote: On 03/11/2015 05:01 AM, Amit Kapila wrote: I have tried without backslash as well, but still it returns same error. pg_rewind.exe -D ..\..\Data --source-pgdata=..\..\Database1 The servers diverged at WAL position

Re: [HACKERS] proposal: searching in array function - array_position

2015-03-12 Thread Pavel Stehule
2015-03-11 22:50 GMT+01:00 Jim Nasby jim.na...@bluetreble.com: On 3/11/15 4:37 PM, Pavel Stehule wrote: + /* + * array_offset - returns the offset of a value in an array (array_offset and + * array_offset_start are wrappers for safe call (look on opr_sanity test) a + *

Re: [HACKERS] patch : Allow toast tables to be moved to a different tablespace

2015-03-12 Thread Julien Tachoires
On 10/03/2015 13:27, Alvaro Herrera wrote: Robert Haas wrote: On Mon, Mar 9, 2015 at 7:26 PM, Andreas Karlsson andr...@proxel.se wrote: I think we should allow moving the indexes for consistency. With this patch we can move everything except for TOAST indexes. It might make sense to always

Re: [HACKERS] proposal: searching in array function - array_position

2015-03-12 Thread Jim Nasby
On 3/10/15 9:30 AM, Robert Haas wrote: On Sat, Mar 7, 2015 at 1:06 PM, Petr Jelinek p...@2ndquadrant.com wrote: You still duplicate the type cache code, but many other array functions do that too so I will not hold that against you. (Maybe somebody should write separate patch that would put all

Re: [HACKERS] Stateful C-language function with state managed by third-party library

2015-03-12 Thread Tom Lane
Denys Rtveliashvili r...@icloud.com writes: My function neeeds to call a third-party library which would create a state and then that state should be kept for the duration of the current query. The library can deallocate that state in a correct way. I understand that fn_extra is normally

Re: [HACKERS] proposal: searching in array function - array_position

2015-03-12 Thread Pavel Stehule
2015-03-10 16:53 GMT+01:00 Jim Nasby jim.na...@bluetreble.com: On 3/10/15 9:30 AM, Robert Haas wrote: On Sat, Mar 7, 2015 at 1:06 PM, Petr Jelinek p...@2ndquadrant.com wrote: You still duplicate the type cache code, but many other array functions do that too so I will not hold that

Re: [HACKERS] proposal: disallow operator = and use it for named parameters

2015-03-12 Thread Pavel Stehule
2015-03-10 17:07 GMT+01:00 Petr Jelinek p...@2ndquadrant.com: On 10/03/15 17:01, Pavel Stehule wrote: 2015-03-10 16:50 GMT+01:00 Tom Lane t...@sss.pgh.pa.us mailto:t...@sss.pgh.pa.us: Robert Haas robertmh...@gmail.com mailto:robertmh...@gmail.com writes: Committed with a