Re: Differences between Postgresql and mysql


Subject: Re: Differences between Postgresql and mysql
From: David Wheeler (David@Wheeler.net)
Date: Tue Oct 09 2001 - 11:56:53 MDT


As a big user and fan of PostgreSQL, I have three responses to this (OT)
thread:

1. The speed of PostgreSQL has everything to do with how you handle
transactions. If you have, for example, AutoCommit turned on in Perl/DBI,
it's going to be slower, because you'll commit your transactions with
every query. This is not efficient (and not good for data integrity,
either). Instead, only commit your transactions when a
conceptually-grouped series of queries completes, and you'll get both a
big speed boost and better data integrity.

2. MySQL does indeed offer transactions and such with their latest
release, but my understanding is that it relies on an external, file-based
DB (Sleepcat DB) to do it, and that slows it way down. I may well be
wrong on the details, though.

3. The speed benefits of MySQL exist for only single-user databases. If
you have a database where you need multiple users to connect (and
certainly if you need 100s or 1000s of concurrent users), PosgreSQL will
win hands down (thanks to its use of MVCC vs. MySQL's table locking).

For more information, there's a fair bit of information on the net
regarding the performance of these two database servers, including some
rather polite debate between the two camps. Here are some links:

On PostgreSQL performance tuning:

 http://www2.linuxjournal.com/lj-issues/issue88/4791.html

A WebTechniques article comparing the two:

  http://www.webtechniques.com/archives/2001/09/jepson/

Some debate between the two camps:

  http://webmail.postgresql.org/~petere/comparison.html

On MVCC in PostgreSQL:

  http://www.linuxgazette.com/issue68/mitchell.html

PostgreSQL TechDocs:

  http://techdocs.postgresql.org/

HTH,

David

-- 
David Wheeler                                         AIM: dwTheory
David@Wheeler.net                                     ICQ: 15726394
                                                   Yahoo!: dew7e
                                                   Jabber: Theory@jabber.org



This archive was generated by hypermail 2a24 : Tue Oct 09 2001 - 11:06:53 MDT