Re: [HACKERS] proposal sql: labeled function params

2008-08-17 Thread Pavel Stehule
2008/8/17 Hannu Krosing <[EMAIL PROTECTED]>: > On Sun, 2008-08-17 at 17:59 +0200, Pavel Stehule wrote: >> Hannu >> >> it's not possible in plpgsql, because we are not able iterate via record. > > just add function for iterating over record :) it's not easy, when iterating should be fast - when rec

Re: [HACKERS] migrate data 6.5.3 -> 8.3.1

2008-08-17 Thread alexander lunyov
Tom Lane wrote: alexander lunyov <[EMAIL PROTECTED]> writes: I want to try new pg_dump to connect to old server, but i can't - old postgres doesn't listening to network socket. It won't work anyway: modern versions of pg_dump are only designed to work with servers back to 7.0. I see from the

Re: [HACKERS] migrate data 6.5.3 -> 8.3.1

2008-08-17 Thread alexander lunyov
Tom Lane wrote: I wonder if you need these self defined aggregates at all, most or all of them are in 8.3 already. They aren't "self defined" in 6.5 either. So i can't just delete those AGGREGATEs? I think what is happening is that he's trying to force a 7.x pg_dump to dump from the 6.5 s

Re: [HACKERS] about postgres-r setup.

2008-08-17 Thread leiyonghua
leiyonghua 写道: Markus Wanner 写道: Hello Leiyonghua, leiyonghua wrote: at node2, and the psql command is hung up, NOTICE: Applying for membership in the communication group... NOTICE: Successfully joined the replication group. Now recovering schema... I've just tested the very same here with

Re: [HACKERS] Patch: plan invalidation vs stored procedures

2008-08-17 Thread Andrew Dunstan
David Fetter wrote: On Sat, Aug 16, 2008 at 09:40:19PM -0400, Tom Lane wrote: "Asko Oja" <[EMAIL PROTECTED]> writes: Is it possible to get it into some official 8.3.x release This is not the kind of patch we put into stable branches. Does this really count as a user-vis

Re: [HACKERS] Overhauling GUCS

2008-08-17 Thread Josh Berkus
Steve, First pass is done. Needs a little cleanup before sharing. I spent a fair while down OS-specific-hardware-queries rathole, but I'm better now. Gods, I hope you gave up on that. You want to use SIGAR or something. --Josh -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresq

Re: [HACKERS] proposal sql: labeled function params

2008-08-17 Thread Robert Haas
> uups, completely forgot dual use of = for both assignment and > comparison. > > Maybe we can do without any "keyword arguments" or "labeled function > params" if we define a way to construct records in-place. That sounds a lot cleaner to me. > something like > RECORD( 'Zdanek'::text AS name, 22

Re: [HACKERS] Patch: plan invalidation vs stored procedures

2008-08-17 Thread David Fetter
On Sat, Aug 16, 2008 at 09:40:19PM -0400, Tom Lane wrote: > "Asko Oja" <[EMAIL PROTECTED]> writes: > > Is it possible to get it into some official 8.3.x release > > This is not the kind of patch we put into stable branches. Does this really count as a user-visible change, except in the sense that

Re: [HACKERS] proposal sql: labeled function params

2008-08-17 Thread Hannu Krosing
On Sun, 2008-08-17 at 18:24 -0400, Robert Haas wrote: > > Actually the most "natural" syntax to me is just f(name=value) similar > > to how UPDATE does it. It has the added benefit of _not_ forcing us to > > make a operator reserved (AFAIK "=" can't be used to define new ops) > > The problem with

Re: [HACKERS] Overhauling GUCS

2008-08-17 Thread Steve Atkins
On Aug 17, 2008, at 1:48 PM, Greg Smith wrote: On Wed, 13 Aug 2008, Michael Nacos wrote: Hi there... Configuration autotuning is something I am really interested in. I have seen this page: http://wiki.postgresql.org/wiki/ GUCS_Overhaul and a couple of emails mentioning this, so I wanted to

Re: [HACKERS] proposal sql: labeled function params

2008-08-17 Thread Robert Haas
> Actually the most "natural" syntax to me is just f(name=value) similar > to how UPDATE does it. It has the added benefit of _not_ forcing us to > make a operator reserved (AFAIK "=" can't be used to define new ops) The problem with this is that SELECT foo(a = b) ...is already valid syntax. It

Re: [HACKERS] Overhauling GUCS

2008-08-17 Thread Greg Smith
On Sun, 17 Aug 2008, Tom Lane wrote: What we have now was named Grand Unified Configuration for a reason: it centralized the handling of what had been a mess of different things configured in different ways. I'm not eager to go backwards on that. No need to change anything related to how the

Re: [HACKERS] proposal sql: labeled function params

2008-08-17 Thread Hannu Krosing
On Sun, 2008-08-17 at 17:59 +0200, Pavel Stehule wrote: > Hannu > > it's not possible in plpgsql, because we are not able iterate via record. just add function for iterating over record :) create or replace function json(r record) returns varchar as $$ select '[' || array_to_string( array(

Re: [HACKERS] IN vs EXISTS equivalence

2008-08-17 Thread Tom Lane
If you're still interested in testing CVS HEAD's handling of EXISTS, I've about finished what I wanted to do with it. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/ma

Re: [HACKERS] Overhauling GUCS

2008-08-17 Thread Tom Lane
Greg Smith <[EMAIL PROTECTED]> writes: > Josh Berkus and I have been exchanging some ideas for the GUC internals > overhaul and had a quick discussion about that in person last month. > We've been gravitating toward putting all the extra information we'd like > to push into there in an extra cat

Re: [HACKERS] API for Managing pg_hba and postgresql.conf

2008-08-17 Thread Greg Smith
On Thu, 14 Aug 2008, Andrew Satori wrote: What I'm seeing is a default installation protects the Data directory properly, but in so doing means that altering the configuration files, pg_hba.conf and postgresql.conf require database administrators, who should not necessarily have a level of rig

Re: [HACKERS] Overhauling GUCS

2008-08-17 Thread Greg Smith
On Wed, 13 Aug 2008, Michael Nacos wrote: Hi there... Configuration autotuning is something I am really interested in. I have seen this page: http://wiki.postgresql.org/wiki/GUCS_Overhaul and a couple of emails mentioning this, so I wanted to ask is someone already on it? If yes, I'd like to con

Re: [HACKERS] pgbench duration option

2008-08-17 Thread Greg Smith
On Tue, 12 Aug 2008, Tom Lane wrote: This seems like a fairly bad idea, because it introduces a gettimeofday() call per transaction. There's already lots of paths through pgbench that introduce gettimeofday calls all over the place. I fail to see how this is any different. If this were wo

Re: [HACKERS] proposal sql: labeled function params

2008-08-17 Thread Pavel Stehule
2008/8/17 Asko Oja <[EMAIL PROTECTED]>: > Not able to means not implementable o not implemented ? Almost not implementable - plpgsql is too static language. > > On Sun, Aug 17, 2008 at 6:59 PM, Pavel Stehule <[EMAIL PROTECTED]> > wrote: >> >> Hannu >> >> it's not possible inNot able to plpgsql,

[HACKERS] any psql static binary for iphone ?

2008-08-17 Thread Oleg Bartunov
Hi there, is there psql static binary, which I can use on my iphone (version 1) ? I have no mac available, so I can't compile it myself. I heard about gui tool for iphone, but it's not free and is only available from apple store, which I have no access. Regards, Oleg __

Re: [HACKERS] [PgFoundry] Unsigned Data Types

2008-08-17 Thread Asko Oja
I can say that we have had several times to use bigint instead because of the lack of uint type in postgres. On Sun, Aug 17, 2008 at 9:03 PM, Ryan Bradetich <[EMAIL PROTECTED]>wrote: > On Sat, Aug 16, 2008 at 10:53 AM, Decibel! <[EMAIL PROTECTED]> wrote: > >> On Aug 15, 2008, at 1:00 AM, Ryan Bra

Re: [HACKERS] proposal sql: labeled function params

2008-08-17 Thread Gregory Stark
"Pavel Stehule" <[EMAIL PROTECTED]> writes: > 2008/8/17 Hannu Krosing <[EMAIL PROTECTED]>: >> On Sun, 2008-08-17 at 08:06 +0200, Pavel Stehule wrote: >>> 2008/8/16 Decibel! <[EMAIL PROTECTED]>: >>> > SQL-like would be value AS name, but I'm not a fan of putting the value >>> > before the name. And

Re: [HACKERS] proposal sql: labeled function params

2008-08-17 Thread Asko Oja
Not able to means not implementable o not implemented ? On Sun, Aug 17, 2008 at 6:59 PM, Pavel Stehule <[EMAIL PROTECTED]>wrote: > Hannu > > it's not possible inNot able to plpgsql, because we are not able iterate > via record. > > Pavel > > 2008/8/17 Hannu Krosing <[EMAIL PROTECTED]>: > > On Su

Re: [HACKERS] [PgFoundry] Unsigned Data Types

2008-08-17 Thread Ryan Bradetich
On Sat, Aug 16, 2008 at 10:53 AM, Decibel! <[EMAIL PROTECTED]> wrote: > On Aug 15, 2008, at 1:00 AM, Ryan Bradetich wrote: > >> Here is the first pass at the unsigned data type I have been working on. >> >> I am planning on adding these to the September 2008 commitfest wiki page. >> The unsigned d

Re: [HACKERS] proposal sql: labeled function params

2008-08-17 Thread Pavel Stehule
Hannu it's not possible in plpgsql, because we are not able iterate via record. Pavel 2008/8/17 Hannu Krosing <[EMAIL PROTECTED]>: > On Sun, 2008-08-17 at 11:08 -0400, Tom Lane wrote: >> Hannu Krosing <[EMAIL PROTECTED]> writes: >> > Actually the most "natural" syntax to me is just f(name=value)

Re: [HACKERS] proposal sql: labeled function params

2008-08-17 Thread Hannu Krosing
On Sun, 2008-08-17 at 11:08 -0400, Tom Lane wrote: > Hannu Krosing <[EMAIL PROTECTED]> writes: > > Actually the most "natural" syntax to me is just f(name=value) similar > > to how UPDATE does it. It has the added benefit of _not_ forcing us to > > make a operator reserved (AFAIK "=" can't be used

Re: [HACKERS] proposal sql: labeled function params

2008-08-17 Thread Pavel Stehule
2008/8/17 Hannu Krosing <[EMAIL PROTECTED]>: > On Sun, 2008-08-17 at 08:06 +0200, Pavel Stehule wrote: >> 2008/8/16 Decibel! <[EMAIL PROTECTED]>: >> > On Aug 15, 2008, at 1:20 PM, Hannu Krosing wrote: >> >>> >> >>> "value AS name", on the other hand, accomplishes the same in a more >> >>> SQL-looki

Re: [HACKERS] Mini improvement: statement_cost_limit

2008-08-17 Thread Hans-Jürgen Schönig
this entire thing is not about cartesian products at all. it is about kicking out "expensive" queries before they even start to eat up tons of CPU. imagine a user asking for "give me all phone call in the US within the past 10 years". you could kill the guy instantly because you know that

Re: [HACKERS] proposal sql: labeled function params

2008-08-17 Thread Tom Lane
Hannu Krosing <[EMAIL PROTECTED]> writes: > Actually the most "natural" syntax to me is just f(name=value) similar > to how UPDATE does it. It has the added benefit of _not_ forcing us to > make a operator reserved (AFAIK "=" can't be used to define new ops) *What* are you thinking?

Re: [HACKERS] proposal sql: labeled function params

2008-08-17 Thread Hannu Krosing
On Sun, 2008-08-17 at 08:06 +0200, Pavel Stehule wrote: > 2008/8/16 Decibel! <[EMAIL PROTECTED]>: > > On Aug 15, 2008, at 1:20 PM, Hannu Krosing wrote: > >>> > >>> "value AS name", on the other hand, accomplishes the same in a more > >>> SQL-looking fashion with no new reserved word (since AS is al

Re: [HACKERS] Replay attack of query cancel

2008-08-17 Thread Magnus Hagander
Tom Lane wrote: > Alvaro Herrera <[EMAIL PROTECTED]> writes: >> Andrew Gierth wrote: >>> 2. The server accepts either the old-style or the secure cancel >>> request from the client, but doesn't allow old-style requests >>> once a valid secure request has been seen. > >> Hmm, I think there should b