Re: [HACKERS] SQL2011 and writeable CTE

2010-11-07 Thread Pavel Stehule
2010/11/8 Hitoshi Harada : > 2010/11/8 Peter Eisentraut : >> On sön, 2010-11-07 at 21:28 +0900, Hitoshi Harada wrote: >>> I've read this Peter's post: >>> >>> http://petereisentraut.blogspot.com/2010/04/news-from-sql-standard.html >>> >>> which says in SQL2011 has a new feature: >>> >>> > Combined

Re: [HACKERS] UNION ALL has higher cost than inheritance

2010-11-07 Thread Tom Lane
I wrote: > The oversight here is that we don't use appendrel planning for > a top-level UNION ALL construct. That didn't use to matter, > because you always got the same stupid Append plan either way. > Now it seems like we ought to have some more intelligence for the > top-level SetOp case. I sm

Re: [HACKERS] SQL2011 and writeable CTE

2010-11-07 Thread Hitoshi Harada
2010/11/8 Peter Eisentraut : > On sön, 2010-11-07 at 21:28 +0900, Hitoshi Harada wrote: >> I've read this Peter's post: >> >> http://petereisentraut.blogspot.com/2010/04/news-from-sql-standard.html >> >> which says in SQL2011 has a new feature: >> >> > Combined data change and retrieval. PostgreSQL

Re: [HACKERS] How to share the result data of separated plan

2010-11-07 Thread Hitoshi Harada
2010/11/8 Tom Lane : > Marko Tiikkaja writes: >> On 2010-11-07 6:23 PM +0200, Tom Lane wrote: >>> Um ... why?  I thought the whole point of breaking out ModifyTable >>> as a separate node type was so that a query involving writeable CTEs >>> would still be just one plan tree. > >> We tried that fo

Re: [HACKERS] SQL/MED estimated time of arrival?

2010-11-07 Thread Shigeru HANADA
On Fri, 05 Nov 2010 10:43:45 -0400 Tom Lane wrote: > Shigeru HANADA writes: > > Thanks, now I see your point. Current FdwRoutine has no appropriate > > function because Open is called from ExecutorStart which is used by > > EXPLAIN too. > > > But then we have mismatch between executor node inte

Re: [HACKERS] sorted writes for checkpoints

2010-11-07 Thread Greg Smith
Jeff Janes wrote: Assuming the ordering is useful, the only way the OS can do as good a job as the checkpoint code can, is if the OS stores the entire checkpoint worth of data as dirty blocks and doesn't start writing until an fsync comes in. This strikes me as a pathologically configured OS/FS

Re: [HACKERS] Buildfarm client version 4.3 released

2010-11-07 Thread Andrew Dunstan
On 11/07/2010 05:34 PM, Andrew Dunstan wrote: Buildfarm client version 4.3 has been released. It can be downloaded from A small bug was in this release, so it has been withdrawn, and replaced with a new release 4.4. cheers andrew -- Sent v

Re: [HACKERS] [PATCH] Revert default wal_sync_method to fdatasync on Linux 2.6.33+

2010-11-07 Thread Greg Smith
Tom Lane wrote: I'm hoping that Greg Smith will take the lead on testing this, since he seems to have spent the most time in the area so far. It's not coincidence that the chapter of my book I convinced the publisher to release as a sample is the one that covers this area; this mess has be

Re: [HACKERS] How to share the result data of separated plan

2010-11-07 Thread Robert Haas
On Sun, Nov 7, 2010 at 1:08 PM, Tom Lane wrote: > Marko Tiikkaja writes: >> On 2010-11-07 6:23 PM +0200, Tom Lane wrote: >>> Um ... why?  I thought the whole point of breaking out ModifyTable >>> as a separate node type was so that a query involving writeable CTEs >>> would still be just one plan

[HACKERS] Buildfarm client version 4.3 released

2010-11-07 Thread Andrew Dunstan
Buildfarm client version 4.3 has been released. It can be downloaded from Changes: * Add setnotes.pl, allowing users to set a note on their animals. * Support buildfarm client maintained git mirror, original suggestion from Rémi

Re: [HACKERS] SQL2011 and writeable CTE

2010-11-07 Thread Peter Eisentraut
On sön, 2010-11-07 at 21:28 +0900, Hitoshi Harada wrote: > I've read this Peter's post: > > http://petereisentraut.blogspot.com/2010/04/news-from-sql-standard.html > > which says in SQL2011 has a new feature: > > > Combined data change and retrieval. PostgreSQL does something like this > > with

Re: [HACKERS] Patch to add a primary key using an existing index

2010-11-07 Thread Gurjeet Singh
Attached is the patch that extends the same feature for UNIQUE indexes. It also includes some doc changes for the ALTER TABLE command, but I could not verify the resulting changes since I don't have the doc-building infrastructure installed. Regards, On Mon, Nov 8, 2010 at 1:39 AM, Gurjeet Singh

Re: [HACKERS] How to share the result data of separated plan

2010-11-07 Thread Marko Tiikkaja
On 2010-11-07 8:08 PM +0200, Tom Lane wrote: Marko Tiikkaja writes: On 2010-11-07 6:23 PM +0200, Tom Lane wrote: Um ... why? I thought the whole point of breaking out ModifyTable as a separate node type was so that a query involving writeable CTEs would still be just one plan tree. We trie

Re: [HACKERS] How to share the result data of separated plan

2010-11-07 Thread Tom Lane
Marko Tiikkaja writes: > On 2010-11-07 6:23 PM +0200, Tom Lane wrote: >> Um ... why? I thought the whole point of breaking out ModifyTable >> as a separate node type was so that a query involving writeable CTEs >> would still be just one plan tree. > We tried that for 9.0 and it didn't work. Al

Re: [HACKERS] Patch to add a primary key using an existing index

2010-11-07 Thread Gurjeet Singh
Depesz brought that to my attention a few days after the initial submission, and adding support for UNIQUE was not much pain. I implemented it almost immediately, but didn't announce it as I was hoping I could submit some doc changes too with that. If you are the adventurous kind, you can follow t

Re: [HACKERS] How to share the result data of separated plan

2010-11-07 Thread Marko Tiikkaja
On 2010-11-07 6:23 PM +0200, Tom Lane wrote: Hitoshi Harada writes: Up to now, in a portal we only have multiple plans that share nothing but relations, then executor starts, runs and ends separately. Writeable CTEs need the result tuplestore of separated plans that were executed before main qu

Re: [HACKERS] How to share the result data of separated plan

2010-11-07 Thread Tom Lane
Hitoshi Harada writes: > Up to now, in a portal we only have multiple plans that share nothing > but relations, then executor starts, runs and ends separately. > Writeable CTEs need the result tuplestore of separated plans that were > executed before main query . Um ... why? I thought the whole

Re: [HACKERS] Query Plan Columns

2010-11-07 Thread Roberto Mello
On Sat, Nov 6, 2010 at 6:24 PM, David E. Wheeler wrote: > > Would I be right that "Node Type" is the only column can be NOT NULL? > > Also, I'm thinking of making the "Actual Startup Time" and ""Actual Total > Time" columns into INTERVALs. The times are expressed in milliseconds, yes? > I'm wond

[HACKERS] How to share the result data of separated plan

2010-11-07 Thread Hitoshi Harada
f you have some thoughts, please let us know. Regards, -- Hitoshi Harada wcte_pquery_experimental.20101107.patch Description: Binary data -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers

[HACKERS] SQL2011 and writeable CTE

2010-11-07 Thread Hitoshi Harada
I've read this Peter's post: http://petereisentraut.blogspot.com/2010/04/news-from-sql-standard.html which says in SQL2011 has a new feature: > Combined data change and retrieval. PostgreSQL does something like this with > RETURNING, but this feature is more elaborate and allows the writing of

Re: [HACKERS] ALTER TABLE ... IF EXISTS feature?

2010-11-07 Thread Daniel Farina
On Sat, Nov 6, 2010 at 6:09 PM, Robert Haas wrote: > Since we now have PL/pgsql by default, we could possibly fix pg_dump > --clean by emitting a DO block, although the syntax for checking > existence of a table is none too pretty, and it would make pg_dump > --clean rely for correctness on plpgsq