MySQL vs. PostgreSQL

Many readers responded to mysql / microsoft tax post by asking why I hadn’t considered postgreSQL as an RDBMS platform. The reason for this is simple: when it comes to infrastructure software (like an rdbms), I’m a mainstream buyer, not an early adopter. What mainstream buyers do is base their behavior on other buyers, relying on the market to make the decision for them.

If postgreSQL is so great, why do we have a LAMP stack instead of a LAPP stack? Why do all the linux hosting companies offer MYSql databases instead of PostgreSQL databases? Why doesn’t any blogging software run on PostgreSQL?
These data points leave me with the impression (and we’re talking about impressions here remember, not reality) that PostgreSQL is a technical success but a market also-ran. As a mainstream technology buyer, I want to use the most mainstream thing that meets my needs: this makes it easier to get support, hire developers, integrate with other software libraries, etc, etc.
After googling this issue a bit, it seems that focussing on making the rdbms dead-simple and really fast was the path to mysql’s success. Postgres built an enterprise rdbms that was too heavy for the average hobby user. And the armies of hobby users gave MySql a buzz that they have ridden all the way to the bank!
Jepson at Webtechniques had this to say:
If you’re migrating from Oracle, Sybase, or Microsoft SQL Server, I suggest PostgreSQL. Like those databases, PostgreSQL has triggers, stored procedures, and a rich set of built-in functions (including many functions for date manipulation). Also, PostgreSQL procedural language is easy to learn if you’re familiar with Oracle’s PL/SQL and SQL Server’s Transact-SQL.
The freebsd forums basically say the same thing:
I’ve always looked at MySQL as “light weight” and PostgresSQL as “complete”. You you need an enterprise solution, I would go for PG, but if you just want to run a simple web app, go with MySQL or even SQLite.
MySQL and PostgreSQL will (probably) eventually converge on both features and speed. Unfortunately, the two took two divergent paths to get to the same destination. MySQL focused on speed and ease-of-use (IMHO) first, then work on adding advanced db features…PostgreSQL, on the other hand, strove for correctness and an adheranace to SQL standards at the beginning. Now that most features are complete, they are left to optimize.

This article
covers the decision-making process in greater detail.
Some choice excerpts from PostgreSQL vs. MySQL: which is better?

MySQL is much more widely used, so many more applications support MySQL, and there is a larger community ready to assist you with problems, as well as more books and resources on MySQL. MySQL AB, the commercial company guiding MySQL, and who employ most of the developers, offer various levels of support contracts …. MySQL claims in its press releases to be extremely stable, but the ‘word on the street’ is that this isn’t true.

The Utah PHP users group had this to say
If you’re trying to help a client or customer or manager decide what database should be used, marketing and branding apply. If your client has heard of individual database engines, the most likely ones they’ll know about are Oracle, Microsoft SQL Server, and MySQL. Selling them on PostgreSQL can be an uphill battle if they haven’t heard of it before, though billing it as practically “an open-source Oracle” may do the trick, and is probably relatively accurate. PgSQL is the closest free and open-source equivalent to Oracle.
Personally, I will consider using PostgreSQL, but I’ll need to do a bit more research to make sure that the hosting and community is there. It will be a much tougher sell than MySQL would have been, simply because MySQL has gained such widespread market acceptance.
I’ll keep everyone posted as I work through this decision. Thanks for your feedback so far!

2 thoughts on “MySQL vs. PostgreSQL

  1. Josh Chamas September 11, 2005 / 2:15 pm

    Hi Jon,

    Interesting decision process about which database to choose.

    I would recommend you give MySQL a chance. Here are some key advantages MySQL offers:

    A well-established company, MySQL AB, with whom you can get key services including support, training, and consulting when you need it.
    A huge community. We boast accurately over 6 million installations.
    Enterprise ready with 5.0. The main features that PostgreSQL has supported historically that we have not are now available in 5.0, which is soon going to production/GA release. These features include triggers, views, and stored procedures.
    A large 3rd party & partner community. Especially with the advent of 5.0, large vendors are rallying support for MySQL and supporting our database platform with their tools. Such partners include Business Objects, Quest, Embarcadero, and the list is ever growing.



    Josh Chamas
    Director, Professional Services
    MySQL Inc.,
    Get More with MySQL!

  2. Anthony Barker September 20, 2005 / 9:02 am

    In business you need to differentiate yourself to keep ahead of the pack. Anyway postresql _is_ mainstream in Japan. 3rd in market share and supported by Fujitsu. Other support companies include: Redhat, SRA, Pervasive, Command Prompt, GreenPlum enterprisedb.

Comments are closed.