[PATCHES] lc_time and localized dates

2008-02-25 Thread Euler Taveira de Oliveira
Hi, Attached is a patch that replaces the lc_messages with lc_time when using to_char in translation mode (TM) [1]. It doesn't change the output behaviour. Per discussion [2], it's using some cache mechanism so we don't need to call setlocale() all the time. Some issues: (i) some locales don

Re: [PATCHES] Fix for initdb failures on Vista

2008-02-25 Thread Heikki Linnakangas
Dave Page wrote: The attached patch fixes problems reported primarily on Vista, but also on some Windows 2003 and XP installations in which initdb reports that it cannot find postgres.exe. A couple of minor nitpicks: Regarding the AddUserToDaclCleanup helper function, I would suggest putting

Re: [PATCHES] [BUGS] Incomplete docs for restore_command for hot standby

2008-02-25 Thread Markus Bertheau
2008/2/22, Simon Riggs <[EMAIL PROTECTED]>: > On Thu, 2008-02-21 at 08:01 +0600, Markus Bertheau wrote: > > > > Section 24.3.3.1 states about restore_command: > > > > "The command will be asked for file names that are not present in the > > archive; it must return nonzero when so asked." > >

Re: [PATCHES] Avahi support for Postgresql

2008-02-25 Thread Peter Eisentraut
Am Dienstag, 27. November 2007 schrieb Mathias Hasselmann: > I don't know, if the 4th patch adding subtypes describing Postgresql's > capabilities is wanted by the Postgresql community. Being a desktop guy, > using Postgresql as embedded database, I'd really like to see all of the > patches merged,

Re: [HACKERS] [PATCHES] Avahi support for Postgresql

2008-02-25 Thread Alvaro Herrera
Mathias Hasselmann wrote: > The patches were in my initial mail, but now I've also uploaded them to > my personal site for convenience: > > http://taschenorakel.de/files/pgsql-avahi-support/ Hmm, a quick look at the third patch reveals that it is using the "threaded" Avahi client. That's

Re: [PATCHES] Avahi support for Postgresql

2008-02-25 Thread Peter Eisentraut
Am Dienstag, 27. November 2007 schrieb Mathias Hasselmann: > Postmaster already has code to announce its services via DNS-SD > (ZeroConf) by using Apple's Bonjour API. This series of patches > implements that capability on top of the Avahi library[1] which > is free software, available for a wider

Re: [PATCHES] Fix pgstatindex using for large indexes

2008-02-25 Thread Zdenek Kotala
Tom Lane napsal(a): Tatsuhito Kasahara <[EMAIL PROTECTED]> writes: In pgstatindex.c and pgstattuple.sql, some variables are defined with int type. So when we try to get informations about a large index by using pgstatindex, we get strange value of size and density. Because the values exceed int-

Re: [PATCHES] lc_time and localized dates

2008-02-25 Thread Zdenek Kotala
Euler Taveira de Oliveira napsal(a): Hi, Hi Some issues: (i) some locales don't capitalize the first letter. I'm using pg_toupper() to do the job but I'm afraid it's not appropriated. I'm using it 'cause i'm too lazy to move localized_str_toupper(). Any suggestions? Please, Day names doe

Re: [PATCHES] Fix pgstatindex using for large indexes

2008-02-25 Thread Andrew Dunstan
Tom Lane wrote: Is there any currently supported platform which does not have uint64? I don't know, and neither do you. Maybe we should look at some reasonable way of getting the info out of a compiled instance. How about if we get pg_config to output the value of INT64_IS_

Re: [PATCHES] Fix pgstatindex using for large indexes

2008-02-25 Thread Tom Lane
Zdenek Kotala <[EMAIL PROTECTED]> writes: > Tom Lane napsal(a): >> Most places where we've dealt with this before, we use double, which is >> guaranteed to be available whereas uint64 is not ... > Is this requirement still valid? Yes. > Is there any currently supported platform which > does not

Re: [PATCHES] Fix pgstatindex using for large indexes

2008-02-25 Thread Tom Lane
Andrew Dunstan <[EMAIL PROTECTED]> writes: > Tom Lane wrote: >>> Is there any currently supported platform which >>> does not have uint64? >> >> I don't know, and neither do you. > Maybe we should look at some reasonable way of getting the info out of a > compiled instance. How about if we get p

Re: [PATCHES] Fix pgstatindex using for large indexes

2008-02-25 Thread Joshua D. Drake
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Mon, 25 Feb 2008 11:21:18 -0500 Tom Lane <[EMAIL PROTECTED]> wrote: > > IIRC we are going to change datetime to integer for 8.4. > > We are going to change the *default* to integer. Thank goodness. Now I can stop recompiling rpms. Thanks for thi

Re: [PATCHES] Avahi support for Postgresql

2008-02-25 Thread Peter Eisentraut
Am Samstag, 23. Februar 2008 schrieb Mathias Hasselmann: > The patches were in my initial mail, but now I've also uploaded them to > my personal site for convenience: > > http://taschenorakel.de/files/pgsql-avahi-support/ I have reworked the first three of your patches (mostly formatting and

Re: [PATCHES] Avahi support for Postgresql

2008-02-25 Thread Mathias Hasselmann
Am Montag, den 25.02.2008, 15:45 +0100 schrieb Peter Eisentraut: > Am Dienstag, 27. November 2007 schrieb Mathias Hasselmann: > > Postmaster already has code to announce its services via DNS-SD > > (ZeroConf) by using Apple's Bonjour API. This series of patches > > implements that capability on to

Re: [PATCHES] Avahi support for Postgresql

2008-02-25 Thread Mathias Hasselmann
Am Montag, den 25.02.2008, 15:27 +0100 schrieb Peter Eisentraut: > Am Dienstag, 27. November 2007 schrieb Mathias Hasselmann: > > I don't know, if the 4th patch adding subtypes describing Postgresql's > > capabilities is wanted by the Postgresql community. Being a desktop guy, > > using Postgresql

Re: [PATCHES] Avahi support for Postgresql

2008-02-25 Thread Tom Lane
Mathias Hasselmann <[EMAIL PROTECTED]> writes: > Oh, that difference is really interesting. I didn't even see it. > DNS-SD uses the convention "_._" to describe services, > and that's the convention Avahi follows. I don't know why the Bonjour > API uses that trailing dot, but it seems wrong: Is

Re: [PATCHES] Avahi support for Postgresql

2008-02-25 Thread Mathias Hasselmann
Am Montag, den 25.02.2008, 19:12 +0100 schrieb Peter Eisentraut: > Am Samstag, 23. Februar 2008 schrieb Mathias Hasselmann: > > The patches were in my initial mail, but now I've also uploaded them to > > my personal site for convenience: > > > > http://taschenorakel.de/files/pgsql-avahi-suppor

[PATCHES] Shlib exports file refactoring

2008-02-25 Thread Peter Eisentraut
After seeing four nearly-identical copies of multiplatform shared library exports file generation code, I figured this should be put in a common place. If you like, please test the attached patch on darwin and win32, since these platforms are mostly affected (besides linux) and I can't test the

[PATCHES] SRF memory leaks

2008-02-25 Thread Neil Conway
Attached is a patch that fixes the SRF memory leaks I recently reported on -hackers[1]. The patch creates a distinct memory context for the SRF's "multi_call_memory_ctx", and then deletes that context when the SRF finishes. This ensures that any user allocations made in this context are reclaimed.

Re: [PATCHES] lc_time and localized dates

2008-02-25 Thread Euler Taveira de Oliveira
Zdenek Kotala wrote: Please, Day names does not have capitalized first letter in Czech language. We have "pondeli" as a Monday. If locale does not do that it is probably intention :-). Hmmm... I don't know about that. I do it that way 'cause I'm concerned about some locales that don't capita

Re: [PATCHES] Fix pgstatindex using for large indexes

2008-02-25 Thread Florian G. Pflug
Tom Lane wrote: Zdenek Kotala <[EMAIL PROTECTED]> writes: Tom Lane napsal(a): Most places where we've dealt with this before, we use double, which is guaranteed to be available whereas uint64 is not ... Is this requirement still valid? Yes. Maybe we should just bite the bullet, and implem

Re: [PATCHES] Fix pgstatindex using for large indexes

2008-02-25 Thread Tom Lane
"Florian G. Pflug" <[EMAIL PROTECTED]> writes: > Maybe we should just bite the bullet, and implement int64 emulation > for platforms that don't provide one? Why? Workarounds such as "use double where needed" have served us perfectly fine so far, with far less effort and notational ugliness than t

Re: [PATCHES] SRF memory leaks

2008-02-25 Thread Tom Lane
Neil Conway <[EMAIL PROTECTED]> writes: > if (funcTupdesc) > + { > tupledesc_match(node->tupdesc, funcTupdesc); > + FreeTupleDesc(funcTupdesc); > + } > } I find this part of the patch to be a seriously bad idea.

Re: [PATCHES] Shlib exports file refactoring

2008-02-25 Thread Tom Lane
Peter Eisentraut <[EMAIL PROTECTED]> writes: > After seeing four nearly-identical copies of multiplatform shared library > exports file generation code, I figured this should be put in a common place. > > If you like, please test the attached patch on darwin and win32, since these > platforms