Re: [HACKERS] Passing tabular data around using python functions

2012-07-31 Thread Jan UrbaƄski
On 30/07/12 14:33, Achim Domma wrote: Hi, Hi Achim, this list is meant for discussing the development of PostgreSQL, in the future you might want to ask your question on pgsql-general. However, to answer your question: I call the function like this: select * from

[HACKERS] [PATCH] Patch to compute Max LSN of Data Pages

2012-07-31 Thread Amit kapila
Based on the discussion and suggestions in this mail chain, following features can be implemented: 1. To compute the value of max LSN in data pages based on user input whether he wants it for an individual file, a particular directory or whole database. 2a. To search the available

Re: [HACKERS] pgsql_fdw in contrib

2012-07-31 Thread Etsuro Fujita
Hi KaiGai-san, Sorry about the delay in answering. I have been swamped with another thing lately. BTW, your patch does not make sense in my environment that is just after initdb without any parameter customizing. Could you give us the step to reproduce the Nested-Loop plan from Hash-Join? I

[HACKERS] JSON function reference in docs

2012-07-31 Thread Thom Brown
Hi, Could we add a reference from the JSON data type page to the JSON functions page akin to how we do for the XML data type? Something like the attached patch. Cheers Thom json_docs_link.patch Description: Binary data -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)

Re: [HACKERS] [patch] libpq one-row-at-a-time API

2012-07-31 Thread Merlin Moncure
On Mon, Jul 30, 2012 at 10:26 PM, Jan Wieck janwi...@yahoo.com wrote: On 7/30/2012 10:31 PM, Leon Smith wrote: This is not necessarily true, on multiple levels. I mean, some of the programs I write are highly concurrent, and this form of batching would have almost no risk of stalling the

Re: [HACKERS] several problems in pg_receivexlog

2012-07-31 Thread Alvaro Herrera
Excerpts from Magnus Hagander's message of jue jul 12 07:35:11 -0400 2012: On Tue, Jul 10, 2012 at 6:45 PM, Fujii Masao masao.fu...@gmail.com wrote: When an error happens after replication connection has been established, pg_receivexlog doesn't close an open file descriptor and release an

Re: [HACKERS] several problems in pg_receivexlog

2012-07-31 Thread Alvaro Herrera
Excerpts from Fujii Masao's message of mar jul 17 13:58:38 -0400 2012: You're right. If the error is detected, that function always returns false and the error message is emitted (but I think that current error message pg_basebackup: child process exited with error 1 is confusing),

[HACKERS] Fixing syslogger rotation logic for first-time case

2012-07-31 Thread Tom Lane
We've had a couple of complaints recently from people who were unhappy because the syslogger's log_truncate_on_rotation logic does not fire during the first log rotation after it's forked off from the postmaster. The key reason for that was that to know whether to truncate or not, the code has to

Re: [HACKERS] several problems in pg_receivexlog

2012-07-31 Thread Fujii Masao
On Wed, Aug 1, 2012 at 12:09 AM, Alvaro Herrera alvhe...@commandprompt.com wrote: Excerpts from Fujii Masao's message of mar jul 17 13:58:38 -0400 2012: You're right. If the error is detected, that function always returns false and the error message is emitted (but I think that current

Re: [HACKERS] Covering Indexes

2012-07-31 Thread Jeff Davis
On Thu, 2012-07-26 at 12:13 -0400, Bruce Momjian wrote: So, do we want a TODO item about adding columns to a unique index that will not be used for uniqueness checks? -1 from me, at least in its current form. At it's heart, this is about separating the constraint from the index that enforces

Re: [HACKERS] PostgreSQLs Extension

2012-07-31 Thread Anderson C. Carniel
Hi! Thanks for quick response. you can create new data types, new operators, new types of indexes if you want... the question is, what are you trying to do? I want to define a new type of geographic data, as well as the PostGIS's data. Also, my intention is to define new topological

[HACKERS] Help me develop new commit_delay advice

2012-07-31 Thread Peter Geoghegan
Many of you will be aware that the behaviour of commit_delay was recently changed. Now, the delay only occurs within the group commit leader backend, and not within each and every backend committing a transaction:

Re: [HACKERS] [NOVICE] Learning SQL: nested CTE and UNION

2012-07-31 Thread Tom Lane
Adam Mackler adammack...@gmail.com writes: ... But this does not work: WITH outmost AS ( SELECT 1 UNION (WITH innermost as (SELECT 2) SELECT * FROM innermost UNION SELECT 3) ) SELECT * FROM outmost; Result: ERROR: relation innermost does not exist LINE 4:

[HACKERS] build postgresql on Mac OS X mountain lion with ossp-uuid

2012-07-31 Thread Palle Girgensohn
Hi, On the new Darwin 10.8 (aka mountain lion), I had to add #ifdef __APPLE__ #if (__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ = 1080) #define _XOPEN_SOURCE #endif #endif to the very beginning of contrib/uuid-ossp/uuid-ossp.c to get the build working with --with-ossp-uuid. I suggested

Re: [HACKERS] New statistics for WAL buffer dirty writes

2012-07-31 Thread Robert Haas
On Sat, Jul 28, 2012 at 6:33 PM, Jeff Janes jeff.ja...@gmail.com wrote: A concern I have is whether the XLogCtlWrite *Write pointer needs to be declared volatile, to prevent the compiler from pushing operations on them outside of the locks (and so memory barriers) that formally protect them.

Re: [HACKERS] build postgresql on Mac OS X mountain lion with ossp-uuid

2012-07-31 Thread Tom Lane
Palle Girgensohn gir...@pingpong.net writes: Hi, On the new Darwin 10.8 (aka mountain lion), I had to add #ifdef __APPLE__ #if (__ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ = 1080) #define _XOPEN_SOURCE #endif #endif to the very beginning of contrib/uuid-ossp/uuid-ossp.c to get the

Re: [HACKERS] New statistics for WAL buffer dirty writes

2012-07-31 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: IMHO, the way we have it now is kind of a mess. SpinLockAcquire and SpinLockRelease are required to be CPU barriers, but they are not required to be compiler barriers. If we changed that so that they were required to act as barriers of both flavors,

Re: [HACKERS] proposal - assign result of query to psql variable

2012-07-31 Thread David Fetter
On Sat, Jul 28, 2012 at 06:11:21PM +0200, Pavel Stehule wrote: Hello 2012/7/27 Tom Lane t...@sss.pgh.pa.us: Pavel Stehule pavel.steh...@gmail.com writes: 2012/7/26 David Fetter da...@fetter.org: How about \gset var1,,,var2,var3... I don't like this - you can use fake variable - and

Re: [HACKERS] JSON function reference in docs

2012-07-31 Thread Tom Lane
Thom Brown t...@linux.com writes: Could we add a reference from the JSON data type page to the JSON functions page akin to how we do for the XML data type? Something like the attached patch. Seems reasonable; committed. regards, tom lane -- Sent via pgsql-hackers