Re: [HACKERS] Alpha releases: How to tag

2009-08-08 Thread Robert Haas
On Aug 7, 2009, at 11:50 PM, Bruce Momjian br...@momjian.us wrote: David Fetter wrote: Odds are that the patch submitters will not understand enough to know how to modify pg_migrator, but just knowing something broke is usually enough for the hackers group to find a fix. This is a pretty

Re: [HACKERS] hot standby - merged up to CVS HEAD

2009-08-08 Thread Bruce Momjian
Robert Haas wrote: On Fri, Aug 7, 2009 at 11:33 PM, Bruce Momjianbr...@momjian.us wrote: Third, Robert, you should have communicated to the list that you were going to work on the patch, so that there would not be duplicate effort if someone else was also working on it. ?As I understood it,

Re: [HACKERS] pg_dump Add dumping of comments on index columns

2009-08-08 Thread Bruce Momjian
Tom Lane wrote: Brendan Jurd dire...@gmail.com writes: I've also done an initial review of the patch. Everything looks sane and the patch works as advertised. I made a couple of minor tweaks for code-style and comment consistency, and my version 3 is attached. I'm marking this patch

Re: [HACKERS] pg_dump Add dumping of comments on index columns

2009-08-08 Thread Brendan Jurd
2009/8/8 Bruce Momjian br...@momjian.us: Just to verify, this patch was about comments on composite columns, not about dumping comments on index columns (as the subject states), right? We do have a TODO for index column comments: Correct. If you scroll up a couple of messages [1] you'll see

Re: [HACKERS] hot standby - merged up to CVS HEAD

2009-08-08 Thread Robert Haas
On Fri, Aug 7, 2009 at 11:33 PM, Bruce Momjianbr...@momjian.us wrote: Third, Robert, you should have communicated to the list that you were going to work on the patch, so that there would not be duplicate effort if someone else was also working on it.  As I understood it, Heikki was in control

Re: [HACKERS] WIP: to_char, support for EEEE format

2009-08-08 Thread Brendan Jurd
2009/8/3 Tom Lane t...@sss.pgh.pa.us: Uh, no, we had better support more.  The actual limit of the current numeric format is 1e+131072. Given your comment above I'm thinking it reasonable to use an int32 to store the exponent -- will that be safe? That would allow for a maximum of 10 exponent

Re: [HACKERS] Split-up ECPG patches

2009-08-08 Thread Michael Meskes
On Fri, Aug 07, 2009 at 04:03:38PM +0200, Boszormenyi Zoltan wrote: I added notice about the PostgreSQL license. Is it ok? Or should I resend without indicating the authors? Normally all our source files are Copyright PostgreSQL Global Development Group and I don't see a reason why this should

Re: [HACKERS] Split-up ECPG patches

2009-08-08 Thread Michael Meskes
On Fri, Aug 07, 2009 at 12:08:00PM -0400, Alvaro Herrera wrote: I think we're normally OK with mentioning the authors, i.e. Author: Yes, it's OK, but I think we normally only acknowledge the author in our commit messages, don't we? such and such, but the (C) line should attribute copyright to

[HACKERS] Patch : seq scan readahead (WIP)

2009-08-08 Thread Pierre Frédéric Caillau d
This is a spinoff of the current work on compression... I've discovered that linux doesn't apply readahead to sparse files. So I added a little readahead in seq scans. Then I realized this might also be beneficial for the standard Postgres. On my RAID1 it shows some pretty drastic effects. The

Re: [HACKERS] Patch : seq scan readahead (WIP)

2009-08-08 Thread Albert Cervera i Areny
A Dissabte, 8 d'agost de 2009, Pierre Frédéric Caillaud va escriure: I guess it would need some experimenting with the values, and a per-tablespace setting, but since lots of people use Linux Software RAID1 on servers, this might be interesting... You guys want to try it ? Your tests involve

Re: [HACKERS] Split-up ECPG patches

2009-08-08 Thread Boszormenyi Zoltan
Michael Meskes írta: On Fri, Aug 07, 2009 at 12:08:00PM -0400, Alvaro Herrera wrote: I think we're normally OK with mentioning the authors, i.e. Author: Yes, it's OK, but I think we normally only acknowledge the author in our commit messages, don't we? such and such, but the

Re: [HACKERS] hot standby - merged up to CVS HEAD

2009-08-08 Thread Robert Haas
On Sat, Aug 8, 2009 at 12:02 AM, Bruce Momjianbr...@momjian.us wrote: Well, Simon stated that your version should now be used as the most recent one, so I would call that a success. Fair enough, but it still needs more work. I had some review comments I was hoping to get responses to, in the

Re: [HACKERS] [PATCH] 2PC state files on shared memory

2009-08-08 Thread Heikki Linnakangas
Tom Lane wrote: Michael Paquier michael.paqu...@gmail.com writes: Based on an idea of Heikki Linnakangas, here is a patch in order to improve 2PC by sending the state files of prepared transactions to shared memory instead of disk. I don't understand how this can possibly work. The entire

Re: [HACKERS] GEQO vs join order restrictions

2009-08-08 Thread Robert Haas
On Sun, Jul 19, 2009 at 3:08 PM, Tom Lanet...@sss.pgh.pa.us wrote: Robert Haas robertmh...@gmail.com writes: Tom, do you think the independent subproblem stuff from last night would be worth pursuing? It's worth looking into.  I'm not certain if it will end up being a good idea or not.  

Re: [HACKERS] [PATCH] 2PC state files on shared memory

2009-08-08 Thread Robert Haas
On Sat, Aug 8, 2009 at 9:31 AM, Heikki Linnakangasheikki.linnakan...@enterprisedb.com wrote: Tom Lane wrote: Michael Paquier michael.paqu...@gmail.com writes: Based on an idea of Heikki Linnakangas, here is a patch in order to improve 2PC by sending the state files of prepared transactions to

Re: [HACKERS] Split-up ECPG patches

2009-08-08 Thread Michael Meskes
On Mon, Aug 03, 2009 at 06:59:30PM +0200, Boszormenyi Zoltan wrote: Why is this messing with the core grammar? ... Zoltan, could you please explain why you unrolled FORWARD and BACKWARD? I tried applying the rest of your patch, without this unrolling but didn't get any shift/reduce problem.

Re: [HACKERS] Alpha releases: How to tag

2009-08-08 Thread Bruce Momjian
Robert Haas wrote: On Aug 7, 2009, at 11:50 PM, Bruce Momjian br...@momjian.us wrote: David Fetter wrote: Odds are that the patch submitters will not understand enough to know how to modify pg_migrator, but just knowing something broke is usually enough for the hackers group to find a

Re: [HACKERS] [PATCH] 2PC state files on shared memory

2009-08-08 Thread Tom Lane
Heikki Linnakangas heikki.linnakan...@enterprisedb.com writes: Tom Lane wrote: Quite aside from that, the fixed size of shared memory makes this seem pretty impractical. Most state files are small. If one doesn't fit in the area reserved for this, it's written to disk as usual. It's just an

Re: [HACKERS] [PATCH] 2PC state files on shared memory

2009-08-08 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: On Sat, Aug 8, 2009 at 9:31 AM, Heikki Linnakangasheikki.linnakan...@enterprisedb.com wrote: I'm a bit disappointed by the performance gains. I would've expected more, given a decent battery-backed-up cache to buffer the WAL fsyncs. It doesn't seem

Re: [HACKERS] Split-up ECPG patches

2009-08-08 Thread Tom Lane
Michael Meskes mes...@postgresql.org writes: Tom, AFAICT we only need one core grammar change, moving the cursor name to it's own rule that only resolves back to name. This rule should be eliminated by bison during the build process anyway, so I see no problem adding it. It does make the ecpg

Re: [HACKERS] Split-up ECPG patches

2009-08-08 Thread Boszormenyi Zoltan
Michael Meskes írta: On Mon, Aug 03, 2009 at 06:59:30PM +0200, Boszormenyi Zoltan wrote: Why is this messing with the core grammar? ... Zoltan, could you please explain why you unrolled FORWARD and BACKWARD? I tried applying the rest of your patch, without this unrolling

Re: [HACKERS] Split-up ECPG patches

2009-08-08 Thread Boszormenyi Zoltan
Tom Lane írta: Michael Meskes mes...@postgresql.org writes: Tom, AFAICT we only need one core grammar change, moving the cursor name to it's own rule that only resolves back to name. This rule should be eliminated by bison during the build process anyway, so I see no problem adding it. It

Re: [HACKERS] WIP: to_char, support for EEEE format

2009-08-08 Thread Tom Lane
Brendan Jurd dire...@gmail.com writes: 2009/8/3 Tom Lane t...@sss.pgh.pa.us: Uh, no, we had better support more.  The actual limit of the current numeric format is 1e+131072. Given your comment above I'm thinking it reasonable to use an int32 to store the exponent -- will that be safe?

Re: [HACKERS] hot standby - merged up to CVS HEAD

2009-08-08 Thread Simon Riggs
On Sat, 2009-08-08 at 00:02 -0400, Bruce Momjian wrote: Also, to my knowledge, nobody has really looked through the results to see if they are any good, so the success of the endeavor remains in doubt from my point of view. That's a bit of a shame because I am interested in putting some

Re: [HACKERS] ALTER TABLE SET STATISTICS requires AccessExclusiveLock

2009-08-08 Thread Simon Riggs
On Fri, 2009-08-07 at 15:58 -0400, Alvaro Herrera wrote: Tom Lane wrote: Peter Eisentraut pete...@gmx.net writes: Is there a good reason for $subject, other than that the code is entangled with other ALTER TABLE code? I think it could be lower, but it would take nontrivial

Re: [HACKERS] Commitfest 2009-07 - 6 patches moved to Returned with Feedback

2009-08-08 Thread Tom Lane
Robert Haas robertmh...@gmail.com writes: As we are now into the last week of this CommitFest (hopefully), I have moved all of the patches that were listed as Waiting on Author to Returned with Feedback. I feel pretty good about doing this because most of these patches have been waiting on

Re: [HACKERS] Split-up ECPG patches

2009-08-08 Thread Michael Meskes
On Sat, Aug 08, 2009 at 05:48:57PM +0200, Boszormenyi Zoltan wrote: ... /usr/bin/perl ./parse.pl . ../../../../src/backend/parser/gram.y preproc.y /usr/bin/bison -d -o preproc.c preproc.y preproc.y: conflicts: 2 shift/reduce preproc.y: expected 0 shift/reduce conflicts make[4]: ***

Re: [HACKERS] hot standby - merged up to CVS HEAD

2009-08-08 Thread Bruce Momjian
Simon Riggs wrote: On Sat, 2009-08-08 at 00:02 -0400, Bruce Momjian wrote: Also, to my knowledge, nobody has really looked through the results to see if they are any good, so the success of the endeavor remains in doubt from my point of view. That's a bit of a shame because I am

Re: [HACKERS] Split-up ECPG patches

2009-08-08 Thread Boszormenyi Zoltan
Michael Meskes írta: On Sat, Aug 08, 2009 at 05:48:57PM +0200, Boszormenyi Zoltan wrote: ... /usr/bin/perl ./parse.pl . ../../../../src/backend/parser/gram.y preproc.y /usr/bin/bison -d -o preproc.c preproc.y preproc.y: conflicts: 2 shift/reduce preproc.y: expected 0 shift/reduce

Re: [HACKERS] Split-up ECPG patches

2009-08-08 Thread Michael Meskes
On Sat, Aug 08, 2009 at 07:21:59PM +0200, Boszormenyi Zoltan wrote: A possible solution would be to force a numeric variable for numeric data. By which you would remove a feature. With the proposed core grammar change, the feature where you can pass the number of records to be fetched

Re: [HACKERS] contrib/pg_freespacemap

2009-08-08 Thread Alvaro Herrera
Tom Lane wrote: Alvaro Herrera alvhe...@commandprompt.com writes: Is there any reason we didn't move the pg_freespace function from contrib to core? Is there a reason we *should* move it? The current definition doesn't leave me feeling that it's more than a low-level hacker's tool. No

Re: [HACKERS] Split-up ECPG patches

2009-08-08 Thread Boszormenyi Zoltan
Michael Meskes írta: On Sat, Aug 08, 2009 at 07:21:59PM +0200, Boszormenyi Zoltan wrote: A possible solution would be to force a numeric variable for numeric data. By which you would remove a feature. With the proposed core grammar change, the feature where you can pass the

Re: [HACKERS] Split-up ECPG patches

2009-08-08 Thread Tom Lane
Boszormenyi Zoltan z...@cybertec.at writes: Michael Meskes írta: The problem is that SignedIconst might be a char variable, too. So how shall the parser know whether str in FETCH BACKWARD :str carries the number of records to move backwards ot the cursor name. This was the problem, yes.

Re: [HACKERS] Split-up ECPG patches

2009-08-08 Thread Boszormenyi Zoltan
Tom Lane írta: Boszormenyi Zoltan z...@cybertec.at writes: Michael Meskes Ă­rta: The problem is that SignedIconst might be a char variable, too. So how shall the parser know whether str in FETCH BACKWARD :str carries the number of records to move backwards ot the cursor name.

Re: [HACKERS] [PATCH] 2PC state files on shared memory

2009-08-08 Thread Heikki Linnakangas
Tom Lane wrote: What if PREPARE simply didn't write the 2PC file at all, except into WAL? Then, make CheckPointTwoPhase write the 2PC file for any still-live GXACT, by means of reaching into the WAL and pulling the data out. All it would need for that is the LSN of the WAL record, which I

Re: [HACKERS] contrib/pg_freespacemap

2009-08-08 Thread Tom Lane
Josh Berkus j...@agliodbs.com writes: Given that the FSM is now auto-managing, is there any reason to have this tool at all? Maybe not, but I'd be inclined to wait a release or so until we have more field experience with the new FSM. If, in a year, FSM is something nobody worries about

Re: [HACKERS] [PATCH] 2PC state files on shared memory

2009-08-08 Thread Tom Lane
Heikki Linnakangas heikki.linnakan...@enterprisedb.com writes: Tom Lane wrote: What if PREPARE simply didn't write the 2PC file at all, except into WAL? Interesting idea, might be worth performance testing. Peeking into the WAL files during normal operation feels naughty, but it should work.

Re: [HACKERS] contrib/pg_freespacemap

2009-08-08 Thread Josh Berkus
On 8/8/09 10:50 AM, Alvaro Herrera wrote: Tom Lane wrote: Alvaro Herrera alvhe...@commandprompt.com writes: Is there any reason we didn't move the pg_freespace function from contrib to core? Is there a reason we *should* move it? The current definition doesn't leave me feeling that it's

Re: [HACKERS] GRANT ON ALL IN schema

2009-08-08 Thread Josh Berkus
Well, since I've written the patch I am for it :) Probably with that GRANT ON * and GRANT ON schema.* as it has indeed very low probability that something like that will be in standard with different meaning and also it's mysql compatible (which is the only db currently having this feature I

Re: [HACKERS] Split-up ECPG patches

2009-08-08 Thread Tom Lane
Boszormenyi Zoltan z...@cybertec.at writes: Tom Lane írta: I'd look at requiring from_in as being the least-bad alternative. Hm. FETCH FORWARD variable can only be a rowcount var only if there's something afterwards, no? With the proposed change in fetch_direction (moving FORWARD and

Re: [HACKERS] Split-up ECPG patches

2009-08-08 Thread Tom Lane
I wrote: The fundamental reason that there's a problem here is that ecpg has decided to accept a syntax that the backend doesn't (ie, FETCH with a fetch direction but no FROM/IN). I think that that's basically a bad idea: it's not helpful to users to be inconsistent, and it requires ugly

Re: [HACKERS] Lock Wait Statistics (next commitfest)

2009-08-08 Thread Mark Kirkwood
Mark Kirkwood wrote: Mark Kirkwood wrote: Jaime Casanova wrote: On Fri, Jul 17, 2009 at 3:38 AM, Mark Kirkwoodmar...@paradise.net.nz wrote: With respect to the sum of wait times being not very granular, yes - quite true. I was thinking it is useful to be able to answer the question 'where

Re: [HACKERS] revised hstore patch

2009-08-08 Thread Bruce Momjian
Tom Lane wrote: Perhaps an appropriate thing to do is separate out the representation change from the other new features, and apply just the latter for now. Or maybe we should think about having two versions of hstore. This is all tied up in the problem of having a decent module

[HACKERS] a short trip in the wayback machine

2009-08-08 Thread Andrew Dunstan
While following up a comment from Tom on my blog, I discovered that some 9 1/2 years ago in a patch bearing the comment: Fixed psql double quoting of SQL ids Fixed libpq printing functions the documentation of psql's --no-readline option was removed (psql-ref.sgml v 1.23). I think

Re: [HACKERS] Docbook toolchain interfering with patch review?

2009-08-08 Thread Bruce Momjian
Robert Haas wrote: Yeah. I usually build the docs and read them if I'm making er proposing... an extensive change, but for simple stuff I just edit the SGML and figure that if it looks sane it probably is. I certainly don't test the doc portions of patches I review unless I see

Re: [HACKERS] Patch for 8.5, transformationHook

2009-08-08 Thread Jeff Davis
On Thu, 2009-07-30 at 00:01 -0400, Robert Haas wrote: The JSON transformation provides functionality which is very similar to what we also offer for XML. I sort of think we ought to just provide that, rather than making it an add-on. I have found it to be a tremendously attractive

Re: [HACKERS] Patch for 8.5, transformationHook

2009-08-08 Thread Jeff Davis
On Mon, 2009-04-20 at 18:53 +0200, Pavel Stehule wrote: b) it allows constructors for data types (ANSI SQL) datatype(typefield1[, typefiedl2[, typefiedl3[, ...]]]) returns type Can you describe this case in more detail? What section of SQL are you referring to? Regards, Jeff Davis

Re: [HACKERS] Commitfest 2009-07 - 6 patches moved to Returned with Feedback

2009-08-08 Thread Robert Haas
On Sat, Aug 8, 2009 at 12:33 PM, Tom Lanet...@sss.pgh.pa.us wrote: Robert Haas robertmh...@gmail.com writes: As we are now into the last week of this CommitFest (hopefully), I have moved all of the patches that were listed as Waiting on Author to Returned with Feedback.  I feel pretty good

Re: [HACKERS] Patch for 8.5, transformationHook

2009-08-08 Thread Robert Haas
On Sat, Aug 8, 2009 at 9:11 PM, Jeff Davispg...@j-davis.com wrote: On Thu, 2009-07-30 at 00:01 -0400, Robert Haas wrote: The JSON transformation provides functionality which is very similar to what we also offer for XML.  I sort of think we ought to just provide that, rather than making it an

Re: [HACKERS] hot standby - merged up to CVS HEAD

2009-08-08 Thread Robert Haas
On Sat, Aug 8, 2009 at 1:12 PM, Bruce Momjianbr...@momjian.us wrote: You are right you don't have to justify anything, but neither can you claim ownership of the patch/feature and complain that others are working on it too.  This is a community project --- if you want your patches to remain

Re: [HACKERS] Patch for 8.5, transformationHook

2009-08-08 Thread Jeff Davis
On Sun, 2009-07-26 at 15:29 +0200, Pavel Stehule wrote: Hello new patch add new contrib transformations with three modules anotation, decode and json. These modules are ported from my older work. Before applying this patch, please use named-fixed patch too. The hook doesn't need it,

Re: [HACKERS] Fixing geometic calculation

2009-08-08 Thread marcin mank
On Sat, Aug 8, 2009 at 3:07 AM, Paul Matthewsp...@netspace.net.au wrote: IEEE754 does not allow two number X and Y, such that X!=Y and (X-Y)==0. And since IEEE754 has been around since the 70's or 80's I think we can start relying on its existence and behavior by now. You are correct, I

Re: [HACKERS] join removal

2009-08-08 Thread Robert Haas
On Sun, Jul 19, 2009 at 10:56 PM, Tom Lanet...@sss.pgh.pa.us wrote: I think we want something along the lines of relation_is_distinct_for with a list of columns and a list of comparison operators, where the first-cut implementation will be to look for matching indexes. This will be different

Re: [HACKERS] Patch for 8.5, transformationHook

2009-08-08 Thread Alvaro Herrera
Jeff Davis escribió: On Mon, 2009-04-20 at 18:53 +0200, Pavel Stehule wrote: b) it allows constructors for data types (ANSI SQL) datatype(typefield1[, typefiedl2[, typefiedl3[, ...]]]) returns type Can you describe this case in more detail? What section of SQL are you referring to?

Re: [HACKERS] Alpha releases: How to tag

2009-08-08 Thread daveg
On Fri, Aug 07, 2009 at 06:28:34PM -0400, Tom Lane wrote: David Fetter da...@fetter.org writes: I am not suggesting that this change be immediate, and it's not ivory tower. It's just how everybody else does it. You keep saying that, and it's completely meaningless. What do you know

Re: [HACKERS] Fixing geometic calculation

2009-08-08 Thread Paul Matthews
marcin mank wrote: You are correct, I think, though this does not solve the division problem: As a first goal I'm just attempting to reduce the EPSILON from 1.0E-6 down to 1.0E-015 (give or take). The current regression test suite works fine down to 1.0E-09. At 1.0E-10 errors appear, not in

Re: [HACKERS] Split-up ECPG patches

2009-08-08 Thread Boszormenyi Zoltan
Tom Lane írta: Boszormenyi Zoltan z...@cybertec.at writes: Tom Lane írta: I'd look at requiring from_in as being the least-bad alternative. Hm. FETCH FORWARD variable can only be a rowcount var only if there's something afterwards, no? With the proposed change in