Re: [HACKERS] Auto-explain patch

2008-08-31 Thread Dean Rasheed
* auto_explain.tgz A contrib module version of auto-explain. An arguable part is initializing instruments in ExecutorRun_hook. The initialization should be done in ExecutorStart normally, but it is too late in the hook. Is it safe? or are there any better idea? README is a plain-text for

[HACKERS] Cause of occasional buildfarm failures in sequence test

2008-08-31 Thread Tom Lane
The current result from buildfarm member pigeon http://www.pgbuildfarm.org/cgi-bin/show_log.pl?nm=pigeondt=2008-08-31%2008:04:54 shows a symptom I've noticed a few times before: everything is fine except that one select * from sequence shows log_cnt = 31 instead of the expected 32. This is a bit

Re: [HACKERS] Cause of occasional buildfarm failures in sequence test

2008-08-31 Thread Hannu Krosing
On Sun, 2008-08-31 at 13:17 -0400, Tom Lane wrote: The current result from buildfarm member pigeon http://www.pgbuildfarm.org/cgi-bin/show_log.pl?nm=pigeondt=2008-08-31%2008:04:54 shows a symptom I've noticed a few times before: everything is fine except that one select * from sequence shows

Re: [HACKERS] Cause of occasional buildfarm failures in sequence test

2008-08-31 Thread Tom Lane
Hannu Krosing [EMAIL PROTECTED] writes: On Sun, 2008-08-31 at 13:17 -0400, Tom Lane wrote: So unless we want to just live with this test failing occasionally, it seems we have two choices: redesign the behavior of nextval() to be insensitive to checkpoint timing, or provide an alternate

[HACKERS] Is this really really as designed or defined in some standard

2008-08-31 Thread Hannu Krosing
It seems that we allow several function arguments to have same name (or is it label :) hannu=# create or replace function ff(a int, a int) returns int language plpgsql as $$begin return $1+$2; end;$$; CREATE FUNCTION hannu=# select ff(1,1); ff 2 (1 row) hannu=# select ff(1,2); ff

Re: [HACKERS] WIP patch: Collation support

2008-08-31 Thread Alvaro Herrera
Radek Strnad escribió: - when creating database with different collation than database cluster, the database has to be reindexed. Any idea how to do it? Function ReindexDatabase works only when database is opened. We have this Todo item: Set proper permissions on non-system schemas during

[HACKERS] [PATCH] In case module has wrong magic, report exact problem

2008-08-31 Thread Marko Kreen
In case module and server magic blocks do not match report exact parameters that differ. It is quite cumbersome problem to track down unless user already knows the cause. As we want to encourage module use, such situations can happen more often.*** a/src/backend/utils/fmgr/dfmgr.c ---

[HACKERS] [PATCH] Make gram.y use palloc/pfree for memory management

2008-08-31 Thread Marko Kreen
Currently gram.y uses malloc/free for memory management, but all pointers are local to function. Unlike flex-based scan.l which has static references to buffers and reuses them across calls. This means gram.y can leak memory if error is throws in the middle of parsing. The patch redefines

[HACKERS] [PATCH] Cleanup of GUC units code

2008-08-31 Thread Marko Kreen
Current GUC units code has 2 problems: - It requires case-sensiteive representation of units (kB). As the main point of units is to make configuring easier, requiring byte-exact typing makes them unnecessarily fragile. - In attempt to preserve maximum range of values for INT64_IS_BUSTED

Re: [HACKERS] Is this really really as designed or defined in some standard

2008-08-31 Thread David Fetter
On Mon, Sep 01, 2008 at 12:55:21AM +0300, Hannu Krosing wrote: It seems that we allow several function arguments to have same name (or is it label :) Ugh! hannu=# create or replace function ff(a int, a int) returns int language plpgsql as $$begin return $1+$2; end;$$; CREATE FUNCTION

Re: [HACKERS] TODO item: Implement Boyer-Moore searching (First time hacker)

2008-08-31 Thread David Rowley
Attached is a patch that I've been working on to implement boyer-moore searching for strpos() and replace(). Benchmarking has been done, it's in spreadsheet format. It can be downloaded from http://www.unixbeast.com/~fat/8.3_test.xls This is my first patch. Please let me know if there is

[HACKERS] Our CLUSTER implementation is pessimal

2008-08-31 Thread Gregory Stark
One thing that's been annoying me for a while is that our CLUSTER implementation is really very slow. When I say very slow I mean it's really very very very slow. The problem is that it does a full index scan and looks up each tuple in the order of the index. That means it a) is doing a lot of

Re: [HACKERS] posix advises ...

2008-08-31 Thread Alvaro Herrera
Greg Smith wrote: This patch does need a bit of general care in a couple of areas. The reviewing game plan I'm working through goes like this: Did this review effort go anywhere? -- Alvaro Herrerahttp://www.CommandPrompt.com/ The PostgreSQL Company -

Re: [HACKERS] [PATCH] Make gram.y use palloc/pfree for memory management

2008-08-31 Thread Tom Lane
Marko Kreen [EMAIL PROTECTED] writes: This means gram.y can leak memory if error is throws in the middle of parsing. Please offer some evidence for that claim. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to

Re: [HACKERS] [PATCH] Cleanup of GUC units code

2008-08-31 Thread Tom Lane
Marko Kreen [EMAIL PROTECTED] writes: - In attempt to preserve maximum range of values for INT64_IS_BUSTED systems, the code is written rather non-obvious way. I do not personally object a bit to making the units comparisons case-insensitive (I think it's mainly Peter who wants to be strict

[HACKERS] WIP: extend parser to show error locations in more cases

2008-08-31 Thread Tom Lane
This is the threatened second pass at reporting parse error locations. It makes the majority of the ereport's in backend/parser/ include an error location. It's not quite ready to apply, mainly because I haven't prepared updated regression test outputs yet (something like 45 out of the 115

Re: [HACKERS] Window functions patch v04 for the September commit fest

2008-08-31 Thread Hitoshi Harada
2008/8/30 Hitoshi Harada [EMAIL PROTECTED]: Here's the latest window functions patch against HEAD. It seems to be ready for the September commit fest, as added documents, WINDOW clause feature and misc tests. I guess this would be the window functions feature freeze for 8.4. The remaining

Re: [HACKERS] Window functions patch v04 for the September commit fest

2008-08-31 Thread David Fetter
On Mon, Sep 01, 2008 at 12:15:19PM +0900, Hitoshi Harada wrote: README is updated. http://umitanuki.net/pgsql/wfv04/design.html Please add link to commit fest wiki. Added :) Cheers, David. -- David Fetter [EMAIL PROTECTED] http://fetter.org/ Phone: +1 415 235 3778 AIM: dfetter666 Yahoo!: