Re: [GENERAL] New FAQ item - Mailing list pgsql-general

From Bruce Momjian
Subject Re: [GENERAL] New FAQ item
Date
Msg-id 199907120239.WAA14130@candle.pha.pa.us
Whole thread Raw
In response to Re: [GENERAL] New FAQ item  ("Ross J. Reedstrom" <reedstrm@wallace.ece.rice.edu>)
List pgsql-general
> On Sat, Jul 10, 1999 at 10:58:20PM -0400, Bruce Momjian wrote:
> >
> > Yes, I agree we compare much more easily to the big guys, but that
> > information may not be getting out as much as it should, so we have to
> > include the obvious MySQL comparison.
> >
>
> The general topic of comparing against MySQL and other dbs came up on the
> Zope mailing list a couple of days ago, in the context of Zope becoming
> multithreaded, and what the db Adaptors needed to support that. I think
> it'd be fruitful to share this post from there with this list. This is
> from a developer who's familiar with the internals of MySQL, not just
> an end user.  One interesting nugget in the middle is a comparision of
> query speed vs. Informix. He mentions that MySQL is faster, but only
> if the selects are simple.  As the queries become complex, the advantage
> gets smaller. Perhaps postgres would be similar, with our (much maligned,
> but IMHO, now pretty damn good) optimizer.

I think you will find that the 6.5 optimizer is a watershed between a
fair optimizer and a now very good optimizer.  Actually, it was always
very good, but there were bugs that make it only fair.  With the bugs
gone, the code runs as it was intended, which is quite good.

I looked at the MySQL code once, and one things that struck me is that
the optimizer is in a single file!  I didn't have to look any farther
than that too see it was limited.  For example, our optimizer has
features like column optimization statistics that Informix did not have
until Informix version 5.  We even have a genetic query optimizer(GEQO)
for really large joins, so we were always world-class in terms of
features.

However, in working with the optimizer with Tom Lane for 6.5, we found
MAJOR bugs that had been there from the Berkeley days that were killing
performance and optimizer choices.

--
  Bruce Momjian                        |  http://www.op.net/~candle
  maillist@candle.pha.pa.us            |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026

pgsql-general by date:

Previous
From: M Simms
Date:
Subject: A few questions
Next
From: Bruce Momjian
Date:
Subject: Re: [GENERAL] A few questions