Re: [HACKERS] [WIP] Performance Improvement by reducing WAL for Update Operation

2012-08-06 Thread Heikki Linnakangas
On 06.08.2012 06:10, Amit Kapila wrote: Currently the solution for fixed length columns cannot handle the case of variable length columns and NULLS. The reason is for fixed length columns there is no need of diff technology between old and new tuple, however for other cases it will be required. F

Re: [HACKERS] postgres 9 bind address for replication

2012-08-06 Thread Magnus Hagander
On Mon, Jul 23, 2012 at 8:45 PM, Andrew Dunstan wrote: > > On 07/23/2012 02:23 PM, Adam Crews wrote: >> >> On Mon, Jul 23, 2012 at 8:34 AM, Robert Haas >> wrote: >>> >>> On Sat, Jul 21, 2012 at 1:24 AM, Adam Crews wrote: Hello, I'm sorry for cross-posting, however I originall

Re: [HACKERS] [WIP] Performance Improvement by reducing WAL for Update Operation

2012-08-06 Thread Amit Kapila
From: Heikki Linnakangas [mailto:heikki.linnakan...@enterprisedb.com] Sent: Monday, August 06, 2012 2:32 PM To: Amit Kapila Cc: 'Bruce Momjian'; pgsql-hackers@postgresql.org Subject: Re: [HACKERS] [WIP] Performance Improvement by reducing WAL for Update Operation On 06.08.2012 06:10, Amit Kapila w

Re: [HACKERS] several problems in pg_receivexlog

2012-08-06 Thread Magnus Hagander
On Tue, Jul 31, 2012 at 5:06 PM, Alvaro Herrera wrote: > > Excerpts from Magnus Hagander's message of jue jul 12 07:35:11 -0400 2012: >> On Tue, Jul 10, 2012 at 6:45 PM, Fujii Masao wrote: > >> > When an error happens after replication connection has been established, >> > pg_receivexlog doesn't

Re: [HACKERS] several problems in pg_receivexlog

2012-08-06 Thread Magnus Hagander
On Tue, Jul 31, 2012 at 6:50 PM, Fujii Masao wrote: > On Wed, Aug 1, 2012 at 12:09 AM, Alvaro Herrera > wrote: >> >> Excerpts from Fujii Masao's message of mar jul 17 13:58:38 -0400 2012: >> >>> >> You're right. If the error is detected, that function always returns >>> >> false >>> >> and the e

Re: [HACKERS] Re: [COMMITTERS] pgsql: Fix mapping of PostgreSQL encodings to Python encodings.

2012-08-06 Thread Heikki Linnakangas
On 20.07.2012 10:13, Jan Urbański wrote: On 20/07/12 08:59, Jan Urbański wrote: On 18/07/12 17:17, Heikki Linnakangas wrote: On 14.07.2012 17:50, Jan Urbański wrote: If pg_do_encoding_conversion() throws an error, you don't get a chance to call Py_DECREF() to release the string. Is that a prob

Re: [HACKERS] WIP patch for LATERAL subqueries

2012-08-06 Thread Robert Haas
On Sun, Aug 5, 2012 at 5:58 PM, Tom Lane wrote: > I've been idly amusing myself by trying to hack up support for > SQL-standard LATERAL subqueries. Cool! > Currently the patch only implements the syntax called out in the standard, > namely that you can put LATERAL in front of a , which is > to s

Re: [HACKERS] WIP Patch: Use sortedness of CSV foreign tables for query planning

2012-08-06 Thread Robert Haas
On Sun, Aug 5, 2012 at 10:41 PM, Etsuro Fujita wrote: > I think file_fdw is useful for managing log files such as PG CSV logs. Since > often, such files are sorted by timestamp, I think the patch can improve the > performance of log analysis, though I have to admit my demonstration was not > real

Re: [HACKERS] Windows Streaming replication -- Windows 2008 servers

2012-08-06 Thread Robert Haas
On Mon, Aug 6, 2012 at 1:41 AM, chinnaobi wrote: > Hi All, It would be helpful if someone tell me, how to verify the streaming > replication started in standby server successfully, just after the service > is started ?? Like knowing the exit code of the service started... It doesn't really work t

Re: [HACKERS] spinlock->pthread_mutex : real world results

2012-08-06 Thread Robert Haas
On Sun, Aug 5, 2012 at 7:19 PM, Nils Goroll wrote: > meanwhile we're using the patch in production (again, this is 9.1.3) and > after running it under full load for one week I believe it is pretty safe to > say that replacing the spinlock code with pthread_mutexes on Linux (which > basically are a

Re: [HACKERS] WIP patch for LATERAL subqueries

2012-08-06 Thread Amit Kapila
From: pgsql-hackers-ow...@postgresql.org [mailto:pgsql-hackers-ow...@postgresql.org] On Behalf Of Robert Haas Sent: Monday, August 06, 2012 6:16 PM On Sun, Aug 5, 2012 at 5:58 PM, Tom Lane wrote: >> Currently the patch only implements the syntax called out in the standard, >> namely that you can

Re: [HACKERS] Statistics and selectivity estimation for ranges

2012-08-06 Thread Heikki Linnakangas
On 04.08.2012 12:31, Alexander Korotkov wrote: Hackers, attached patch is for collecting statistics and selectivity estimation for ranges. In order to make our estimations accurate for every distribution of ranges, we would collect 2d-distribution of lower and upper bounds of range into some ki

Re: [HACKERS] WIP patch for LATERAL subqueries

2012-08-06 Thread Amit Kapila
From: pgsql-hackers-ow...@postgresql.org [mailto:pgsql-hackers-ow...@postgresql.org] On Behalf Of Tom Lane Sent: Monday, August 06, 2012 3:28 AM To: pgsql-hackers@postgreSQL.org Subject: [HACKERS] WIP patch for LATERAL subqueries > I've been idly amusing myself by trying to hack up support for SQL

Re: [HACKERS] tzdata2012d

2012-08-06 Thread Magnus Hagander
On Tue, Jul 31, 2012 at 1:09 AM, Tom Lane wrote: > Alvaro Herrera writes: >> Excerpts from David Fetter's message of lun jul 30 17:27:46 -0400 2012: >>> Can we slide this into the upcoming point release? When would that >>> be? > >> Usually, Tom installs the latest timezone data just before each

Re: [HACKERS] WIP Patch: Use sortedness of CSV foreign tables for query planning

2012-08-06 Thread Tom Lane
Robert Haas writes: > On Sun, Aug 5, 2012 at 10:41 PM, Etsuro Fujita > wrote: >> I think file_fdw is useful for managing log files such as PG CSV logs. Since >> often, such files are sorted by timestamp, I think the patch can improve the >> performance of log analysis, though I have to admit my

Re: [HACKERS] WIP patch for LATERAL subqueries

2012-08-06 Thread Robert Haas
On Mon, Aug 6, 2012 at 10:07 AM, Amit Kapila wrote: >>> Currently the patch only implements the syntax called out in the > standard, >>> namely that you can put LATERAL in front of a , which is >>> to say a parenthesized sub-SELECT in FROM. It strikes me that it might > be >>> worth allowing LATE

Re: [HACKERS] WIP patch for LATERAL subqueries

2012-08-06 Thread Tom Lane
Robert Haas writes: > Apparently Sybase and Microsoft SQL server use a slightly different > syntax, CROSS APPLY, for this. > http://iablog.sybase.com/paulley/2008/07/cross-and-outer-apply/ Well, this is only a blog entry and not their manual, but AFAICT that is just a useless deviation from SQL-

Re: [HACKERS] SP-GiST for ranges based on 2d-mapping and quad-tree

2012-08-06 Thread Heikki Linnakangas
Just to check where we stand on this: Are you going to send a finalized version of this patch, based on the one I sent earlier, or should I pick up that version and try to get it into committable state? On 23.07.2012 10:37, Alexander Korotkov wrote: On Fri, Jul 20, 2012 at 3:48 PM, Heikki Linn

Re: [HACKERS] WIP patch for LATERAL subqueries

2012-08-06 Thread Tom Lane
Robert Haas writes: > I think you can always simulate CROSS APPLY using LATERAL. The syntax > is different but the functionality is the same. However, OUTER APPLY > allows you to do something that I don't think is possible using > LATERAL. Uh, what exactly? AFAICT from that blog entry, "x OUTE

Re: [HACKERS] WIP Patch: Use sortedness of CSV foreign tables for query planning

2012-08-06 Thread Robert Haas
On Mon, Aug 6, 2012 at 10:33 AM, Tom Lane wrote: > Robert Haas writes: >> On Sun, Aug 5, 2012 at 10:41 PM, Etsuro Fujita >> wrote: >>> I think file_fdw is useful for managing log files such as PG CSV logs. >>> Since >>> often, such files are sorted by timestamp, I think the patch can improve t

Re: [HACKERS] WIP patch for LATERAL subqueries

2012-08-06 Thread Robert Haas
On Mon, Aug 6, 2012 at 11:09 AM, Tom Lane wrote: > Robert Haas writes: >> I think you can always simulate CROSS APPLY using LATERAL. The syntax >> is different but the functionality is the same. However, OUTER APPLY >> allows you to do something that I don't think is possible using >> LATERAL.

Re: [HACKERS] tzdata2012d

2012-08-06 Thread Tom Lane
Magnus Hagander writes: > On Tue, Jul 31, 2012 at 1:09 AM, Tom Lane wrote: >> In practice, people who need the latest TZ data shouldn't be relying >> on our copy anyway. I think pretty much all distros build with > That's a "dangerous" thing to say. All the Windows users out there > have no cho

Re: [HACKERS] WIP patch for LATERAL subqueries

2012-08-06 Thread Tom Lane
Robert Haas writes: > On Mon, Aug 6, 2012 at 11:09 AM, Tom Lane wrote: >> Uh, what exactly? AFAICT from that blog entry, "x OUTER APPLY y" is >> exactly the same as "x LEFT JOIN LATERAL y ON true". Okay, so you >> saved three words, but is that a good enough reason to invent a >> nonstandard sy

[HACKERS] Fwd: Statistics and selectivity estimation for ranges

2012-08-06 Thread Matthias
Having statistics on ranges was really missing! The planner was doing some really, really bad choices on bigger tables regarding seq/random scans, nested loop/other joins etc. Is there any chance this makes it into 9.2 final? It would really round-off the introduction of range types and maybe avoi

Re: [HACKERS] Fwd: Statistics and selectivity estimation for ranges

2012-08-06 Thread Josh Berkus
> Is there any chance this makes it into 9.2 final? It would really > round-off the introduction of range types and maybe avoid problems > like "the new range types are slow" (just due to the bad row > estimates). Nope, that's strictly a 9.3 feature. 9.2 is in beta2. -- Josh Berkus PostgreSQL

[HACKERS] Mailsystem maintenance/migration announcement

2012-08-06 Thread Stefan Kaltenbrunner
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hi all! We are currently planning to finalize the ongoing work on the mailsystem migration we started earlier this year by migrating the two remaining components of the postgresql.org mailsystem infrastructure to new systems. Those parts (listserver a

Re: [HACKERS] [PATCH] Docs: Make notes on sequences and rollback more obvious

2012-08-06 Thread Robert Haas
On Sat, Aug 4, 2012 at 12:56 AM, Craig Ringer wrote: > On 08/04/2012 04:12 AM, Kevin Grittner wrote: >> I haven't reviewed it in detail but noticed an apparent editing error: >> "which are used the counters" should probably have an "as" thrown in there. >> Or something. > > Thanks. Editing fail. I

[HACKERS] redundant message?

2012-08-06 Thread Alvaro Herrera
I noticed we have this message in utils/adt/misc.c:176 (9.2 branch): (errmsg("must be superuser or have the same role to terminate backends running in other server processes"; I think the wording "backends running in other server processes" is redundant. How about this? (errmsg("must be

Re: [HACKERS] redundant message?

2012-08-06 Thread Robert Haas
On Mon, Aug 6, 2012 at 2:54 PM, Alvaro Herrera wrote: > I noticed we have this message in utils/adt/misc.c:176 (9.2 branch): > > (errmsg("must be superuser or have the same role to terminate backends > running in other server processes"; > > I think the wording "backends running in other se

Re: [HACKERS] spinlock->pthread_mutex : real world results

2012-08-06 Thread Martijn van Oosterhout
On Mon, Aug 06, 2012 at 08:54:11AM -0400, Robert Haas wrote: > 2. Should we be modifying our spinlock implementation on Linux to use > futexes rather than pulling pthreads into the mix? > > Anyone have data on the first point, or opinions on the second one? I'm not sure whether pthreads is such a

Re: [HACKERS] spinlock->pthread_mutex : real world results

2012-08-06 Thread Nils Goroll
Robert, 1. How much we're paying for this in the uncontended case? Using glibc, we have the overhead of an additional library function call, which we could eliminate by pulling in the code from glibc/nptl or a source of other proven reference code. The pgbench results I had posted before

Re: [HACKERS] WIP patch for LATERAL subqueries

2012-08-06 Thread Amit Kapila
From: Robert Haas [mailto:robertmh...@gmail.com] Sent: Monday, August 06, 2012 8:07 PM On Mon, Aug 6, 2012 at 10:07 AM, Amit Kapila wrote: > I think you can always simulate CROSS APPLY using LATERAL. The syntax > is different but the functionality is the same. However, OUTER APPLY > allows you

[HACKERS] Beta 3

2012-08-06 Thread Craig Ringer
Heya all It seems like it's a bit trickier to find beta downloads than might be ideal. The beta info page simply reads: " PostgreSQL 9.2 beta 3 was released on August 6, 2012." with no information about how to obtain a build or the sources, not even a link to the downloads page, despite

Re: [HACKERS] Statistics and selectivity estimation for ranges

2012-08-06 Thread Alexander Korotkov
On Mon, Aug 6, 2012 at 6:09 PM, Heikki Linnakangas < heikki.linnakan...@enterprisedb.com> wrote: > On 04.08.2012 12:31, Alexander Korotkov wrote: > >> Hackers, >> >> attached patch is for collecting statistics and selectivity estimation for >> ranges. >> >> In order to make our estimations accurat

Re: [HACKERS] WIP Patch: Use sortedness of CSV foreign tables for query planning

2012-08-06 Thread Etsuro Fujita
> From: Robert Haas [mailto:robertmh...@gmail.com] > On Mon, Aug 6, 2012 at 10:33 AM, Tom Lane wrote: > > Robert Haas writes: > >> On Sun, Aug 5, 2012 at 10:41 PM, Etsuro Fujita > >> wrote: > >>> I think file_fdw is useful for managing log files such as PG CSV logs. Since > >>> often, such file