Re: [PATCHES] [GENERAL] Crosstab Problems

2007-10-25 Thread Joe Conway
Joe Conway wrote: Tom Lane wrote: A couple of minor thoughts: * You could reduce the ugliness of many of the tests by introducing a variant strcmp function that does the "right" things with NULL inputs. It might also be worth adding a variant pstrdup that takes a NULL. I had thoughts along th

Re: [PATCHES] [GENERAL] Crosstab Problems

2007-10-25 Thread Joe Conway
Tom Lane wrote: Joe Conway <[EMAIL PROTECTED]> writes: Well, maybe the attached patches better explain what I mean. In the case of the 8.2 patch, a very small code change allows new regression data including NULL rowids to: 1) not crash 2) have no impact otherwise The much bigger 8.3

Re: [PATCHES] [GENERAL] Crosstab Problems

2007-10-25 Thread Tom Lane
Joe Conway <[EMAIL PROTECTED]> writes: > Well, maybe the attached patches better explain what I mean. > In the case of the 8.2 patch, a very small code change allows new > regression data including NULL rowids to: >1) not crash >2) have no impact otherwise > The much bigger 8.3 patch sho

Re: [PATCHES] Autovacuum cancellation

2007-10-25 Thread Alvaro Herrera
Tom Lane wrote: > Gregory Stark <[EMAIL PROTECTED]> writes: > > I think there's a window where the process waiting directly on > > autovacuum could have already fired its deadlock check before it was > > waiting directly on autovacuum. > > I think you don't understand what that code is doing. If

Re: [PATCHES] Autovacuum cancellation

2007-10-25 Thread Tom Lane
Gregory Stark <[EMAIL PROTECTED]> writes: > Can autovacuum actually get into a hard deadlock? It can certainly be part of a deadlock loop, though the practical cases might be few. It will be holding more than one lock, eg a lock on its target table and various transient locks on system catalogs,

Re: [PATCHES] [GENERAL] Crosstab Problems

2007-10-25 Thread Joe Conway
Tom Lane wrote: Joe Conway <[EMAIL PROTECTED]> writes: Tom Lane wrote: 1. Treat NULL rowid as a category in its own right. This would conform with the behavior of GROUP BY and DISTINCT, for instance. In any case, the attached changes the behavior to #1 for both flavors of crosstab (the orig

Re: [PATCHES] Autovacuum cancellation

2007-10-25 Thread Gregory Stark
"Tom Lane" <[EMAIL PROTECTED]> writes: > There's some things still to be desired here: if an autovac process is > involved in a hard deadlock, the patch doesn't favor zapping it over > anybody else, nor consider cancelling the autovac as an alternative to > rearranging queues for a soft deadlock.

Re: [PATCHES] Autovacuum cancellation

2007-10-25 Thread Tom Lane
Alvaro Herrera <[EMAIL PROTECTED]> writes: > Patch attached, please comment. It only avoids cancelling when the > vacuum is for wraparound. I'm not entirely convinced that there can be only one autovac proc in the portion of the waits-for graph explored by DeadlockCheck. If there is more than on

[PATCHES] Minor change to pg_dump docs

2007-10-25 Thread Chris Browne
As suggested to me by Ian Darwin <[EMAIL PROTECTED]>... Index: doc/src/sgml/ref/pg_dump.sgml === RCS file: /projects/cvsroot/pgsql/doc/src/sgml/ref/pg_dump.sgml,v retrieving revision 1.97 diff -c -u -r1.97 pg_dump.sgml --- doc/src/sgm

[PATCHES] Autovacuum cancellation

2007-10-25 Thread Alvaro Herrera
Simon Riggs wrote: > Just noticed you've made these changes. I was working on them, but > hadn't fully tested the patch because of all the different touch points. > Sorry for the delay. > > Would you like me to refresh my earlier patch against the newly > committed state (or did you commit that a

Re: [PATCHES] vacuum as flags in PGPROC

2007-10-25 Thread Alvaro Herrera
Alvaro Herrera wrote: > Hmm, now it's misbehaving strangely. Nevermind, I think I see what's happening. -- Alvaro Herrerahttp://www.CommandPrompt.com/ PostgreSQL Replication, Consulting, Custom Development, 24x7 support ---(end of broadca

Re: [PATCHES] vacuum as flags in PGPROC

2007-10-25 Thread Alvaro Herrera
Tom Lane wrote: > Alvaro Herrera <[EMAIL PROTECTED]> writes: > > Also, I forgot to mention it on the first email, but this patch adds > > errcontext() lines when an autovacuum/analyze is being aborted. It > > works fine, but I'm not seeing code anywhere else that does something > > like this. > >

Re: [PATCHES] two new chklocale aliases

2007-10-25 Thread Alvaro Herrera
Zdenek Kotala wrote: > I add two encoding aliases used in Solaris. Applied, thanks. -- Alvaro Herrera http://www.flickr.com/photos/alvherre/ "Ellos andaban todos desnudos como su madre los parió, y también las mujeres, aunque no vi más que una, harto moza, y todos los que

[PATCHES] Headers dependencies cleanup

2007-10-25 Thread Zdenek Kotala
During my work I found some header files, which include useless headers and on other way there are some headers which silently assume that requested header will be included by some other headers file. This patch fixes these dependencies around bufpage.h, bufmgr.h Zdene

[PATCHES] two new chklocale aliases

2007-10-25 Thread Zdenek Kotala
I add two encoding aliases used in Solaris. Zdenek Index: src/port/chklocale.c === RCS file: /zfs_data/cvs_pgsql/cvsroot/pgsql/src/port/chklocale.c,v retrieving revision 1.6 diff -c -r1.6 chklocale.c *** src/port/chk