Re: [HACKERS] docs: WITH queries and VALUES

2012-04-14 Thread Peter Eisentraut
On tor, 2012-04-12 at 11:59 +0200, Magnus Hagander wrote: The SELECT manpage has: and with_query is: with_query_name [ ( column_name [, ...] ) ] AS ( select | insert | update | delete ) Should that list that you can use values as well? Or is it something we generally consider

Re: [HACKERS] Last gasp

2012-04-14 Thread Alex
Peter Eisentraut pete...@gmx.net writes: On ons, 2012-04-11 at 23:30 -0400, Robert Haas wrote: Now what would be sort of neat is if we had a way to keep all the versions of patch X plus author and reviewer information, links to reviews and discussion, etc. in some sort of centralized place.

Re: [HACKERS] Patch: add timing of buffer I/O requests

2012-04-14 Thread Greg Smith
On 04/13/2012 06:22 PM, Tom Lane wrote: But (a) I *don't* want to seriously break things, and don't see a need to; (b) interval is expensive and has got its own problems, notably an internal limitation to usec resolution that we would not be able to get rid of easily. A straight float seems

Re: [HACKERS] [BUGS] BUG #6572: The example of SPI_execute is bogus

2012-04-14 Thread Pavel Stehule
2012/4/14 Robert Haas robertmh...@gmail.com: On Fri, Apr 13, 2012 at 10:43 PM, Pavel Stehule pavel.steh...@gmail.com wrote: Yeah.  I think it would be a good idea for UPDATE and DELETE to expose a LIMIT option, but I can't really see the virtue in making that functionality available only

Re: [HACKERS] Last gasp

2012-04-14 Thread Greg Smith
On 04/14/2012 03:02 AM, Alex wrote: I didn't follow this whole thread, but have we considered Redmine[1]? It comes up every couple of years in contexts near this one, such as http://wiki.postgresql.org/wiki/TrackerDiscussion -- Greg Smith 2ndQuadrant USg...@2ndquadrant.com

Re: [HACKERS] Last gasp

2012-04-14 Thread Alex
Greg Smith g...@2ndquadrant.com writes: On 04/14/2012 03:02 AM, Alex wrote: I didn't follow this whole thread, but have we considered Redmine[1]? It comes up every couple of years in contexts near this one, such as http://wiki.postgresql.org/wiki/TrackerDiscussion Oh, I see. I wonder

Re: [HACKERS] Last gasp

2012-04-14 Thread Alex
Alex a...@commandprompt.com writes: Greg Smith g...@2ndquadrant.com writes: On 04/14/2012 03:02 AM, Alex wrote: I didn't follow this whole thread, but have we considered Redmine[1]? It comes up every couple of years in contexts near this one, such as

Re: [HACKERS] docs: WITH queries and VALUES

2012-04-14 Thread Magnus Hagander
On Apr 14, 2012 8:09 AM, Peter Eisentraut pete...@gmx.net wrote: On tor, 2012-04-12 at 11:59 +0200, Magnus Hagander wrote: The SELECT manpage has: and with_query is: with_query_name [ ( column_name [, ...] ) ] AS ( select | insert | update | delete ) Should that list that

Re: [HACKERS] missing description initdb manual

2012-04-14 Thread Tatsuo Ishii
--text-search-config option is missing in document too. Also pg_ctl's long name options, such as --silent, are missing in document. Thanks for the info. I will add them as well unless someone beats me. Done. BTW, while editing the document, I noticed that pg_ctl.c's help message lacks some

Re: [HACKERS] xlog location arithmetic

2012-04-14 Thread Fujii Masao
On Sat, Apr 14, 2012 at 5:30 AM, Robert Haas robertmh...@gmail.com wrote: On Mon, Mar 12, 2012 at 10:34 PM, Fujii Masao masao.fu...@gmail.com wrote: I can see a usecase for having a pg_size_pretty(numeric) as an option. Not necessarily a very big one, but a 0 one. +1. +1, too. I did some

[HACKERS] column name of pg_stat_replication.backend_start

2012-04-14 Thread Fujii Masao
Hi, The column name of pg_stat_replication.backend_start is confusing because it's not the time when *backend* was started at all. We should rename it to walsender_start or replication_start? Regards, -- Fujii Masao -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To

Re: [HACKERS] xlog location arithmetic

2012-04-14 Thread Robert Haas
On Sat, Apr 14, 2012 at 7:25 AM, Fujii Masao masao.fu...@gmail.com wrote: On Sat, Apr 14, 2012 at 5:30 AM, Robert Haas robertmh...@gmail.com wrote: On Mon, Mar 12, 2012 at 10:34 PM, Fujii Masao masao.fu...@gmail.com wrote: I can see a usecase for having a pg_size_pretty(numeric) as an option.

Re: [HACKERS] column name of pg_stat_replication.backend_start

2012-04-14 Thread Robert Haas
On Sat, Apr 14, 2012 at 8:00 AM, Fujii Masao masao.fu...@gmail.com wrote: The column name of pg_stat_replication.backend_start is confusing because it's not the time when *backend* was started at all. We should rename it to walsender_start or replication_start? walsenders are backends, of

Re: [HACKERS] [BUGS] BUG #6572: The example of SPI_execute is bogus

2012-04-14 Thread Robert Haas
On Sat, Apr 14, 2012 at 3:27 AM, Pavel Stehule pavel.steh...@gmail.com wrote: It has a lot of sense.  Without it, it's very difficult to do logical replication on a table with no primary key. (Whether or not people should create such tables in the first place is, of course, beside the point.)

Re: [HACKERS] Patch: add timing of buffer I/O requests

2012-04-14 Thread Robert Haas
On Sat, Apr 14, 2012 at 3:27 AM, Greg Smith g...@2ndquadrant.com wrote: On 04/13/2012 06:22 PM, Tom Lane wrote: But (a) I *don't* want to seriously break things, and don't see a need to; (b) interval is expensive and has got its own problems, notably an internal limitation to usec resolution

Re: [HACKERS] Memory usage during sorting

2012-04-14 Thread Greg Stark
On Fri, Apr 13, 2012 at 7:01 PM, Peter Geoghegan pe...@2ndquadrant.com wrote: Well, timsort is specifically designed to take advantage of pre-sorted data. It does appear to have a lot of traction, as wikipedia points out: I hadn't heard of it. But reading up on it it does seem like a good fit

Re: [HACKERS] column name of pg_stat_replication.backend_start

2012-04-14 Thread Magnus Hagander
On Sat, Apr 14, 2012 at 14:22, Robert Haas robertmh...@gmail.com wrote: On Sat, Apr 14, 2012 at 8:00 AM, Fujii Masao masao.fu...@gmail.com wrote: The column name of pg_stat_replication.backend_start is confusing because it's not the time when *backend* was started at all. We should rename it to

Re: [HACKERS] Memory usage during sorting

2012-04-14 Thread Peter Geoghegan
On 14 April 2012 13:32, Greg Stark st...@mit.edu wrote: On Fri, Apr 13, 2012 at 7:01 PM, Peter Geoghegan pe...@2ndquadrant.com wrote: Well, timsort is specifically designed to take advantage of pre-sorted data. It does appear to have a lot of traction, as wikipedia points out: I hadn't

Re: [HACKERS] Patch: add timing of buffer I/O requests

2012-04-14 Thread Peter Geoghegan
On 10 April 2012 19:10, Tom Lane t...@sss.pgh.pa.us wrote: Hmm.  Maybe we should think about numeric ms, which would have all the same advantages but without the round-off error. Color me unimpressed ... numeric calculations are vastly more expensive than float, and where are you going to get

Re: [HACKERS] [COMMITTERS] pgsql: Add new replication mode synchronous_commit = 'write'.

2012-04-14 Thread Fujii Masao
On Sat, Apr 14, 2012 at 4:57 AM, Guillaume Lelarge guilla...@lelarge.info wrote: On 04/13/2012 08:15 PM, Kevin Grittner wrote: Robert Haasrobertmh...@gmail.com  wrote: In my view, remote_write seems a lot more clear than write +1 I sure didn't understand it to mean remote_write when I

Re: [HACKERS] missing description initdb manual

2012-04-14 Thread Tom Lane
Tatsuo Ishii is...@postgresql.org writes: BTW, while editing the document, I noticed that pg_ctl.c's help message lacks some long options which are actually in the source code: '--timeout' and '--mode'. Included is the proposed patch to fix the problem. If there's no objection, I would like

Re: [HACKERS] column name of pg_stat_replication.backend_start

2012-04-14 Thread Fujii Masao
On Sat, Apr 14, 2012 at 10:05 PM, Magnus Hagander mag...@hagander.net wrote: On Sat, Apr 14, 2012 at 14:22, Robert Haas robertmh...@gmail.com wrote: On Sat, Apr 14, 2012 at 8:00 AM, Fujii Masao masao.fu...@gmail.com wrote: The column name of pg_stat_replication.backend_start is confusing

Re: [HACKERS] [COMMITTERS] pgsql: Add new replication mode synchronous_commit = 'write'.

2012-04-14 Thread Robert Haas
On Sat, Apr 14, 2012 at 10:28 AM, Fujii Masao masao.fu...@gmail.com wrote: On Sat, Apr 14, 2012 at 4:57 AM, Guillaume Lelarge guilla...@lelarge.info wrote: On 04/13/2012 08:15 PM, Kevin Grittner wrote: Robert Haasrobertmh...@gmail.com  wrote: In my view, remote_write seems a lot more clear

Re: [HACKERS] [COMMITTERS] pgsql: Add new replication mode synchronous_commit = 'write'.

2012-04-14 Thread Fujii Masao
On Sat, Apr 14, 2012 at 4:16 AM, Thom Brown t...@linux.com wrote: On 13 April 2012 19:15, Kevin Grittner kevin.gritt...@wicourts.gov wrote: Robert Haas robertmh...@gmail.com wrote: In my view, remote_write seems a lot more clear than write +1 I sure didn't understand it to mean

Re: [HACKERS] [COMMITTERS] pgsql: Add new replication mode synchronous_commit = 'write'.

2012-04-14 Thread Thom Brown
On 14 April 2012 15:58, Fujii Masao masao.fu...@gmail.com wrote: On Sat, Apr 14, 2012 at 4:16 AM, Thom Brown t...@linux.com wrote: I have a question though.  What happens when this is set to write (or remote_write as proposed) but it's being used on a standalone primary?  At the moment it's

Re: [HACKERS] [BUGS] BUG #6572: The example of SPI_execute is bogus

2012-04-14 Thread Peter Eisentraut
On lör, 2012-04-14 at 08:23 -0400, Robert Haas wrote: On Sat, Apr 14, 2012 at 3:27 AM, Pavel Stehule pavel.steh...@gmail.com wrote: It has a lot of sense. Without it, it's very difficult to do logical replication on a table with no primary key. (Whether or not people should create such

Re: [HACKERS] [BUGS] BUG #6572: The example of SPI_execute is bogus

2012-04-14 Thread Pavel Stehule
2012/4/14 Peter Eisentraut pete...@gmx.net: On lör, 2012-04-14 at 08:23 -0400, Robert Haas wrote: On Sat, Apr 14, 2012 at 3:27 AM, Pavel Stehule pavel.steh...@gmail.com wrote: It has a lot of sense.  Without it, it's very difficult to do logical replication on a table with no primary key.

Re: [HACKERS] Patch: add timing of buffer I/O requests

2012-04-14 Thread Peter Geoghegan
On 14 April 2012 02:42, Greg Stark st...@mit.edu wrote: Is this not subject to the birthday paradox? If you have a given hash you're worried about a collision with then you have a one-in-four-billion chance. But if you have a collection of hashes and you're worried about any collisions then it

Re: [HACKERS] Different gettext domain needed for error context

2012-04-14 Thread Heikki Linnakangas
On 15.02.2012 20:13, Tom Lane wrote: Heikki Linnakangasheikki.linnakan...@enterprisedb.com writes: To fix this, we need to somehow pass the caller's text domain to errcontext(). The most straightforward way is to pass it as an extra argument. Ideally, errcontext() would be a macro that passes

Re: [HACKERS] Last gasp

2012-04-14 Thread Jay Levitt
Christopher Browne wrote: On Thu, Apr 12, 2012 at 6:11 PM, Jay Levittjay.lev...@gmail.com wrote: Rather than extend the CF app into a trivial-patch workflow app, it might be worth looking at integrating it with github. There's a reluctance to require a proprietary component that could

Re: [HACKERS] Last gasp

2012-04-14 Thread Jay Levitt
Alex wrote: I didn't follow this whole thread, but have we considered Redmine[1]? As the resident Ruby is shiny, let's do everything in Rails on my MacBook guy, I'd like to make a statement against interest: I've tried Redmine a few times and it's been painful. Much of the codebase is

Re: [HACKERS] [BUGS] BUG #6572: The example of SPI_execute is bogus

2012-04-14 Thread Robert Haas
On Sat, Apr 14, 2012 at 12:15 PM, Peter Eisentraut pete...@gmx.net wrote: On lör, 2012-04-14 at 08:23 -0400, Robert Haas wrote: On Sat, Apr 14, 2012 at 3:27 AM, Pavel Stehule pavel.steh...@gmail.com wrote: It has a lot of sense.  Without it, it's very difficult to do logical replication on

Re: [HACKERS] Different gettext domain needed for error context

2012-04-14 Thread Tom Lane
Heikki Linnakangas heikki.linnakan...@enterprisedb.com writes: 3. In the callback function, call a new function to set the domain to be used for the errcontext() calls in that callback: /* use the right domain to translate the errcontext() calls */ set_errtextdomain();

Re: [HACKERS] Last gasp

2012-04-14 Thread Robert Haas
On Tue, Apr 10, 2012 at 8:43 PM, Greg Smith g...@2ndquadrant.com wrote: The main reason I worry about this is because of a very real chicken/egg problem here that I keep banging into.  Since the commit standards for so many other open-source projects are low, there are a non trivial number of

Re: [HACKERS] Patch: add timing of buffer I/O requests

2012-04-14 Thread Robert Haas
On Sat, Apr 14, 2012 at 9:54 AM, Peter Geoghegan pe...@2ndquadrant.com wrote: On 10 April 2012 19:10, Tom Lane t...@sss.pgh.pa.us wrote: Hmm.  Maybe we should think about numeric ms, which would have all the same advantages but without the round-off error. Color me unimpressed ... numeric

Re: [HACKERS] missing description initdb manual

2012-04-14 Thread Tatsuo Ishii
I think this line needs some more thought: -printf(_( -m SHUTDOWN-MODE can be \smart\, \fast\, or \immediate\\n)); +printf(_( -m, --mode SHUTDOWN-MODE can be \smart\, \fast\, or \immediate\\n)); because it's not respecting the intended alignment of the explanation

Re: [HACKERS] Patch: add timing of buffer I/O requests

2012-04-14 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: The internal representation doesn't have to be (and certainly shouldn't be) numeric. But if you translate to numeric before returning the data to the user, then you have the freedom, in the future, to whack around the internal representation however

Re: [HACKERS] Last gasp

2012-04-14 Thread Alex
Jay Levitt jay.lev...@gmail.com writes: Alex wrote: I didn't follow this whole thread, but have we considered Redmine[1]? As the resident Ruby is shiny, let's do everything in Rails on my MacBook guy, I'd like to make a statement against interest: I've tried Redmine a few times and it's