X-Original-To: pgsql-hackers-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 4088BD8E81 for ; Wed, 14 Sep 2005 12:42:55 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 53740-07 for ; Wed, 14 Sep 2005 15:42:52 +0000 (GMT) Received: from davinci.ethosmedia.com (server227.ethosmedia.com [209.128.84.227]) by svr1.postgresql.org (Postfix) with ESMTP id 68FDED8E7F for ; Wed, 14 Sep 2005 12:42:51 -0300 (ADT) X-EthosMedia-Virus-Scanned: no infections found Received: from [63.195.55.98] (account josh@agliodbs.com HELO spooky) by davinci.ethosmedia.com (CommuniGate Pro SMTP 4.1.8) with ESMTP id 8093860; Wed, 14 Sep 2005 08:45:10 -0700 From: Josh Berkus Organization: Aglio Database Solutions To: pgsql-hackers@postgresql.org, jonah.harris@gmail.com Subject: Re: About method of PostgreSQL's Optimizer Date: Wed, 14 Sep 2005 08:44:02 -0700 User-Agent: KMail/1.8 Cc: pryscila.lista@gmail.com References: <36e6829205091320085993ceba@mail.gmail.com> In-Reply-To: <36e6829205091320085993ceba@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200509140844.03449.josh@agliodbs.com> X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.011 required=5 tests=[AWL=0.011] X-Spam-Level: X-Archive-Number: 200509/661 X-Sequence-Number: 73058 Pryscila, > > There are other methods for query optimization, one of them is based on > > plan transformations (for example, using A-Star algorithm) instead of > > plan constructions used by PostgreSQL. We do certainly need a specific optimization for large star-schema joins. I'm not certain that A* is suitable for our cost model, though; I think we might need to work up something more particular to Postgres. > > Does anyone know why this method was choosen? Are there any papers or > > researches about it? There probably are on ACM but I've not read them. Ours is a pretty straightforward implementation of a cost-based optimizer. You can always read the code ;-) Mark Kirkwood put together this nice paper on planner statistics: http://www.powerpostgresql.com/PlanStats -- Josh Berkus Aglio Database Solutions San Francisco