Re: [HACKERS] window function v03 against HEAD

2008-07-31 Thread David Fetter
On Thu, Jul 31, 2008 at 02:46:29PM +0900, Hitoshi Harada wrote: 2008/7/31 David Fetter [EMAIL PROTECTED]: On Thu, Jul 31, 2008 at 02:12:26PM +0900, Hitoshi Harada wrote: 2008/7/29 David Fetter [EMAIL PROTECTED]: On Mon, Jul 28, 2008 at 07:25:55PM +0900, H.Harada wrote: I happily

Re: [HACKERS] [PATCH] \ef function in psql

2008-07-31 Thread Abhijit Menon-Sen
I have attached two patches: - funcdef.diff implements pg_get_functiondef() - edit.diff implements \ef function in psql based on (1). Comments appreciated. -- ams diff --git a/src/include/utils/builtins.h b/src/include/utils/builtins.h index 1ba20b0..ccf0d68 100644 ---

Re: [HACKERS] Type Categories for User-Defined Types

2008-07-31 Thread Dimitri Fontaine
Hi, Le mercredi 30 juillet 2008, David E. Wheeler a écrit : On Jul 30, 2008, at 10:34, Tom Lane wrote: [ move preferred-type info into the system catalogs ] UUID and so on aren't considered part of the string category, and shouldn't be IMHO ... any type that has semantics significantly

Re: [HACKERS] Should creating a new base type require superuser status?

2008-07-31 Thread Andrew Sullivan
On Wed, Jul 30, 2008 at 06:07:53PM -0400, Alvaro Herrera wrote: I do agree that creating base types should require a superuser though. It too seems dangerous just on principle, even if today there's no actual hole (that we already know of). I agree. -- Andrew Sullivan [EMAIL PROTECTED] +1

Re: [HACKERS] window function v03 against HEAD

2008-07-31 Thread Hitoshi Harada
2008/7/31 David Fetter [EMAIL PROTECTED]: On Thu, Jul 31, 2008 at 02:46:29PM +0900, Hitoshi Harada wrote: 2008/7/31 David Fetter [EMAIL PROTECTED]: On Thu, Jul 31, 2008 at 02:12:26PM +0900, Hitoshi Harada wrote: 2008/7/29 David Fetter [EMAIL PROTECTED]: On Mon, Jul 28, 2008 at 07:25:55PM

[HACKERS] Dumping datconfig

2008-07-31 Thread Magnus Hagander
It seems the only way to dump stuff in pg_database.datconfig (ALTER DATABASE foo SET something=bar) is to do an unqualified pg_dumpall. I think this should *at least* be dumped with pg_dump when it's set to create the database, and I think a case could be made that it should *always* be dumped

Re: [HACKERS] Plans for 8.4

2008-07-31 Thread Magnus Hagander
Stephen Frost wrote: * Henry B. Hotz ([EMAIL PROTECTED]) wrote: I'm making no promises, but what would people think of a hostgss hba option? As described, sounds like a win to me. It'd be very nice to be able to just use GSSAPI encryption on the link. That, combined w/ Magnus' work on

Re: [HACKERS] Dumping datconfig

2008-07-31 Thread Magnus Hagander
Magnus Hagander wrote: It seems the only way to dump stuff in pg_database.datconfig (ALTER DATABASE foo SET something=bar) is to do an unqualified pg_dumpall. I think this should *at least* be dumped with pg_dump when it's set to create the database, and I think a case could be made that it

Re: [HACKERS][PATCHES] odd output in restore mode

2008-07-31 Thread Heikki Linnakangas
Martin Zaun wrote: Heikki Linnakangas wrote: Andrew Dunstan wrote: Greg Smith wrote: On Wed, 23 Jul 2008, Kevin Grittner wrote: I've been working on an improved archive_command shell script that I expect to submit for comments and potential inclusion in the documentation as a better base

Re: [HACKERS][PATCHES] odd output in restore mode

2008-07-31 Thread Tom Lane
Heikki Linnakangas [EMAIL PROTECTED] writes: Martin Zaun wrote: With these avenues to be explored, can the pg_standby patch on the CommitFest wiki be moved to the Returned with Feedback section? Yes, I think we can conclude that we don't want this patch as it is. Instead, we want a

Re: [HACKERS] window function v03 against HEAD

2008-07-31 Thread David Fetter
On Thu, Jul 31, 2008 at 11:00:15PM +0900, Hitoshi Harada wrote: 2008/7/31 David Fetter [EMAIL PROTECTED]: Sorry about that. Apparently, at least the way things are set up, there's a *lot* of history you can rewind. Further changes should move pretty quickly :) Thankfully, I succeeded

Re: [HACKERS] pg_regress inputdir

2008-07-31 Thread Alvaro Herrera
Jorgen Austvik - Sun Norway wrote: Do we also agree that if you set --inputdir to anything other than the default, pg_regress will not work (will write a file to one folder, and try to read the same file from another)? And if we agree above - should we make setting --inputdir work (read

Re: [HACKERS] window function v03 against HEAD

2008-07-31 Thread Hitoshi Harada
2008/8/1 David Fetter [EMAIL PROTECTED]: You will be as soon as I can arrange it. I may move or re-create that repository. Please send me a username and an RSA public key so I can give you git-shell access. Thank you for your consideration. But right now, I'm going to be off for three days

Re: [HACKERS] pg_regress inputdir

2008-07-31 Thread Alvaro Herrera
Alvaro Herrera wrote: Jorgen Austvik - Sun Norway wrote: Do we also agree that if you set --inputdir to anything other than the default, pg_regress will not work (will write a file to one folder, and try to read the same file from another)? And if we agree above - should we make

[HACKERS] Fixing DISTINCT ON for duplicate keys

2008-07-31 Thread Tom Lane
I looked into this trouble report: http://archives.postgresql.org/pgsql-sql/2008-07/msg00123.php The problem is that by the time we get to transformDistinctClause(), any duplicate entries in the ORDER BY list have been eliminated (see addTargetToSortList). But transformDistinctClause expects a

Re: [HACKERS] Type Categories for User-Defined Types

2008-07-31 Thread David E. Wheeler
On Jul 30, 2008, at 13:10, Tom Lane wrote: Yes, that was essentially my point. arbitrary string of text types are probably fairly rare, since one can just use text or citext or varchar. Good point --- so new members of STRING category aren't going to be that common, except for domains

[HACKERS] compilig libpq with borland 5.5

2008-07-31 Thread claudio lezcano
Hi everybody Iam traying to build libpq.lib and libpq.dll library using Borland c++ 5.5 and i got these error: Error libpq.rc 1 11: Cannot open file: winver.h I opened the libpq.rc file and i saw the reference to that file #include winver.h I cheched out the path and the existence of the file

Re: [HACKERS] Fixing DISTINCT ON for duplicate keys

2008-07-31 Thread David Fetter
On Thu, Jul 31, 2008 at 01:38:37PM -0400, Tom Lane wrote: I looked into this trouble report: http://archives.postgresql.org/pgsql-sql/2008-07/msg00123.php Comments? It seems to me that DISTINCT ON is just a special case of the more general windowing functions

Re: [HACKERS] Review: DTrace probes (merged version) ver_03

2008-07-31 Thread Alvaro Herrera
Robert Lor wrote: Hi, What I suggest might be a reasonable compromise is to copy needed typedefs directly into the probes.d file: Implemented this suggestion. There are some weirdness with the OS X compiler causing some of the probe declarations not to compile (see comments in

Re: [HACKERS] window function v03 against HEAD

2008-07-31 Thread David Fetter
On Fri, Aug 01, 2008 at 02:13:52AM +0900, Hitoshi Harada wrote: 2008/8/1 David Fetter [EMAIL PROTECTED]: You will be as soon as I can arrange it. I may move or re-create that repository. Please send me a username and an RSA public key so I can give you git-shell access. Thank you for

Re: [HACKERS] Creating Universal OSX binaries

2008-07-31 Thread Tom Lane
Bruce Momjian [EMAIL PROTECTED] writes: Do we know this trick for creating Universal (four-architecture) binaries for OSX? This seems largely irrelevant to CVS HEAD: http://archives.postgresql.org/pgsql-hackers/2008-07/msg00884.php The proposed trick doesn't actually work in any case, since he

Re: [HACKERS] Plans for 8.4

2008-07-31 Thread Henry B. Hotz
On Jul 31, 2008, at 7:58 AM, Magnus Hagander wrote: Stephen Frost wrote: * Henry B. Hotz ([EMAIL PROTECTED]) wrote: I'm making no promises, but what would people think of a hostgss hba option? As described, sounds like a win to me. It'd be very nice to be able to just use GSSAPI

Re: [HACKERS] Fixing DISTINCT ON for duplicate keys

2008-07-31 Thread Tom Lane
David Fetter [EMAIL PROTECTED] writes: It seems to me that DISTINCT ON is just a special case of the more general windowing functions http://archives.postgresql.org/pgsql-hackers/2008-07/msg01277.php Harada-san has been working on. Could these use the same machinery? Perhaps at some point we

Re: [HACKERS] Should creating a new base type require superuser status?

2008-07-31 Thread Kris Jurka
On Wed, 30 Jul 2008, Alvaro Herrera wrote: I think being able to return cstring from a user defined function is quite dangerous already. I doubt we would ever give that capability to non-superusers. I do agree that creating base types should require a superuser though. It too seems

Re: [HACKERS] Fixing DISTINCT ON for duplicate keys

2008-07-31 Thread David Fetter
On Thu, Jul 31, 2008 at 03:10:35PM -0400, Tom Lane wrote: David Fetter [EMAIL PROTECTED] writes: It seems to me that DISTINCT ON is just a special case of the more general windowing functions http://archives.postgresql.org/pgsql-hackers/2008-07/msg01277.php Harada-san has been working on.

Re: [HACKERS] Review: DTrace probes (merged version) ver_03

2008-07-31 Thread Robert Lor
Alvaro Herrera wrote: But I don't see a reason to define the rest: +typedef unsigned int locktag_field2; +typedef const char * query_string; +typedef int sortType; +typedef int trueFalse; +typedef int nkeys; +typedef int workMem; +typedef int randomAccess; +typedef unsigned long

Re: [HACKERS] Review: DTrace probes (merged version) ver_03

2008-07-31 Thread Alvaro Herrera
Robert Lor wrote: That Mac OS X problem merits some extra investigation, I think. I'm investigating this one and will find the root cause, but I don't think it should hold back this patch. Other than this, I think this patch can be committed. I'd appreciate if it can be committed

Re: [HACKERS] Review: DTrace probes (merged version) ver_03

2008-07-31 Thread Alvaro Herrera
Robert Lor wrote: Tom Lane wrote: * The probes that pass buffer tag elements are already broken by the pending relation forks patch: there is soon going to be another field in buffer tags. Perhaps it'd be feasible to pass the buffer tag as a single probe argument to make that a bit more

Re: [HACKERS] Should creating a new base type require superuser status?

2008-07-31 Thread Tom Lane
Kris Jurka [EMAIL PROTECTED] writes: On Wed, 30 Jul 2008, Alvaro Herrera wrote: I do agree that creating base types should require a superuser though. It too seems dangerous just on principle, even if today there's no actual hole (that we already know of). pl/java already allows

Re: [HACKERS] Review: DTrace probes (merged version) ver_03

2008-07-31 Thread Alvaro Herrera
Here's what I have. Please confirm that this compiles for you. -- Alvaro Herrerahttp://www.CommandPrompt.com/ PostgreSQL Replication, Consulting, Custom Development, 24x7 support Index: src/backend/access/transam/clog.c

[HACKERS] Fixing the representation of ORDER BY/GROUP BY/DISTINCT

2008-07-31 Thread Tom Lane
So while I was fooling with Steve Midgley's problem I got a bit of a bee in my bonnet about the way that the parser emits ORDER BY, GROUP BY, and DISTINCT lists. * Currently, ORDER BY and DISTINCT use lists of SortClause, while GROUP BY is a list of GroupClause --- but these are actually the same

Re: [HACKERS] Copy storage parameters on CREATE TABLE LIKE/INHERITS

2008-07-31 Thread ITAGAKI Takahiro
Tom Lane [EMAIL PROTECTED] wrote: There are a couple of other things that need to be thought about: * LIKE is intended to copy a table as a *portion* of another table; You're absolutely right. I just thought it's a *better default* behavior because LIKE and INHERITS are often used in single

Re: [HACKERS] Review: DTrace probes (merged version) ver_03

2008-07-31 Thread Robert Lor
Alvaro Herrera wrote: Here's what I have. Please confirm that this compiles for you. I made some changes to the sed script so it works with the sed on Solaris OS X. I tested this patch on both Solaris and OS X with DTrace enabled and disabled and also verified that the sed script works

Re: [HACKERS] Review: DTrace probes (merged version) ver_03

2008-07-31 Thread Robert Lor
Alvaro Herrera wrote: I was checking the DTrace docs for other reasons and I came across this, which maybe can be useful here: http://docs.sun.com/app/docs/doc/817-6223/chp-xlate?a=view Yes, I think using the translator is the best approach to expose internal structures in a stable