> -----Original Message----- > From: Tom Lane [mailto:[EMAIL PROTECTED] > Sent: Tuesday, December 13, 2005 7:38 PM > To: Dann Corbit > Cc: Qingqing Zhou; Luke Lonergan; Neil Conway; Bruce Momjian; pgsql- > [EMAIL PROTECTED] > Subject: Re: [HACKERS] Which qsort is used > > "Dann Corbit" <[EMAIL PROTECTED]> writes: > > The in-order check happens only once > > Hm? What about that call inside qloop's loop?
You're right. Once per partition of size 50 or greater. In my tests, it was a clear win. We'll see in the Qingqing Zhou test setup if it helps or not. If there is some order to the data, it will be of benefit. For purely random samples, there will be a small fixed cost. ---------------------------(end of broadcast)--------------------------- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match