Re: Simple Join
От
Mitch Skinner
Тема
Re: Simple Join
Дата
Msg-id
1134644526.14248.60.camel@firebolt
Ответ на
Re: Simple Join (Kevin Brown)
Список
Дерево обсуждения
Simple Join Kevin Brown <blargity@gmail.com>
Re: Simple Join "Steinar H. Gunderson" <sgunderson@bigfoot.com>
Re: Simple Join Mark Kirkwood <markir@paradise.net.nz>
Re: Simple Join Kevin Brown <blargity@gmail.com>
Re: Simple Join Mark Kirkwood <markir@paradise.net.nz>
Re: Simple Join Kevin Brown <blargity@gmail.com>
Re: Simple Join Mark Kirkwood <markir@paradise.net.nz>
Re: Simple Join Mark Kirkwood <markir@paradise.net.nz>
Re: Simple Join Tom Lane <tgl@sss.pgh.pa.us>
Re: Simple Join Mitchell Skinner <mitch@arctur.us>
Re: Simple Join Kevin Brown <blargity@gmail.com>
Re: Simple Join Mitch Skinner <lists@arctur.us>
Re: Simple Join Mark Kirkwood <markir@paradise.net.nz>
Overriding the optimizer "Craig A. James" <cjames@modgraph-usa.com>
Re: Overriding the optimizer Tom Lane <tgl@sss.pgh.pa.us>
Re: Overriding the optimizer "Craig A. James" <cjames@modgraph-usa.com>
Re: Overriding the optimizer Tom Lane <tgl@sss.pgh.pa.us>
Re: Overriding the optimizer David Lang <dlang@invendra.net>
Re: Overriding the optimizer "Craig A. James" <cjames@modgraph-usa.com>
Re: Overriding the optimizer Christopher Kings-Lynne <chriskl@familyhealth.com.au>
Re: Overriding the optimizer "Craig A. James" <cjames@modgraph-usa.com>
Re: Overriding the optimizer Jaime Casanova <systemguards@gmail.com>
Re: Overriding the optimizer Christopher Kings-Lynne <chriskl@familyhealth.com.au>
Re: Overriding the optimizer "Craig A. James" <cjames@modgraph-usa.com>
Re: Overriding the optimizer Mitch Skinner <lists@arctur.us>
Re: Overriding the optimizer Kevin Brown <kevin@sysexperts.com>
Re: Overriding the optimizer Christopher Kings-Lynne <chriskl@familyhealth.com.au>
Re: Overriding the optimizer "Craig A. James" <cjames@modgraph-usa.com>
Re: Overriding the optimizer Christopher Kings-Lynne <chriskl@familyhealth.com.au>
Re: Overriding the optimizer "Craig A. James" <cjames@modgraph-usa.com>
Re: Overriding the optimizer Christopher Kings-Lynne <chriskl@familyhealth.com.au>
Re: Overriding the optimizer "Craig A. James" <cjames@modgraph-usa.com>
Re: Overriding the optimizer Mark Kirkwood <markir@paradise.net.nz>
Re: Overriding the optimizer "Jim C. Nasby" <jnasby@pervasive.com>
Re: Overriding the optimizer "Craig A. James" <cjames@modgraph-usa.com>
Re: Overriding the optimizer Kevin Brown <kevin@sysexperts.com>
Re: Overriding the optimizer "Craig A. James" <cjames@modgraph-usa.com>
Re: Overriding the optimizer Kevin Brown <kevin@sysexperts.com>
Re: Overriding the optimizer "Jim C. Nasby" <jnasby@pervasive.com>
Re: Overriding the optimizer Bruno Wolff III <bruno@wolff.to>
Re: Overriding the optimizer Kyle Cordes <kyle@kylecordes.com>
Re: Overriding the optimizer Jaime Casanova <systemguards@gmail.com>
Re: Overriding the optimizer "Craig A. James" <cjames@modgraph-usa.com>
Re: Overriding the optimizer Kyle Cordes <kyle@kylecordes.com>
Re: Overriding the optimizer Mark Kirkwood <markir@paradise.net.nz>
Re: Overriding the optimizer Tomasz Rybak <bogomips@post.pl>
Re: Overriding the optimizer "Jim C. Nasby" <jnasby@pervasive.com>
Re: Overriding the optimizer Jaime Casanova <systemguards@gmail.com>
Re: Overriding the optimizer "Jim C. Nasby" <jnasby@pervasive.com>
Re: Overriding the optimizer "Craig A. James" <cjames@modgraph-usa.com>
Re: Overriding the optimizer Jaime Casanova <systemguards@gmail.com>
Re: Overriding the optimizer David Lang <dlang@invendra.net>
Re: Overriding the optimizer David Lang <dlang@invendra.net>
Re: Overriding the optimizer Jaime Casanova <systemguards@gmail.com>
Re: Simple Join David Lang <dlang@invendra.net>
Re: Simple Join Mark Kirkwood <markir@paradise.net.nz>
Re: Simple Join Kevin Brown <blargity@gmail.com>
Re: Simple Join Bruce Momjian <pgman@candle.pha.pa.us>
Re: Simple Join Jaime Casanova <systemguards@gmail.com>
Re: Simple Join Kevin Brown <blargity@gmail.com>
On Thu, 2005-12-15 at 01:48 -0600, Kevin Brown wrote: > > Well, I'm no expert either, but if there was an index on > > ordered_products (paid, suspended_sub, id) it should be mergejoinable > > with the index on to_ship.ordered_product_id, right? Given the > > conditions on paid and suspended_sub. > > > The following is already there: > > CREATE INDEX ordered_product_id_index > ON to_ship > USING btree > (ordered_product_id); > > That's why I emailed this list. I saw that; what I'm suggesting is that that you try creating a 3-column index on ordered_products using the paid, suspended_sub, and id columns. In that order, I think, although you could also try the reverse. It may or may not help, but it's worth a shot--the fact that all of those columns are used together in the query suggests that you might do better with a three-column index on those. With all three columns indexed individually, you're apparently not getting the bitmap plan that Mark is hoping for. I imagine this has to do with the lack of multi-column statistics in postgres, though you could also try raising the statistics target on the columns of interest. Setting enable_seqscan to off, as others have suggested, is also a worthwhile experiment, just to see what you get. Mitch
В списке pgsql-performance по дате отправления
От: Markus Schaber
Дата: