Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

 

Behind the PostgreSQL Module

We've released a module that lets SilverStripe work with PostgreSQL.

by Geoff Munn

Posted 1 June 2010

Read post

We've released a module that lets SilverStripe work with PostgreSQL. I've been the primary coder working on the PostgreSQL module for the past year, and the work we did on this, alongside changes to the core Sapphire framework, have been released as part of version 2.4.

Some limitations of MySQL were becoming issues for us over the past few years. One of them was that the storage engines, InnoDB and MyISAM, each had advantages that the other didn't, while Postgres is a single storage engine with all of those benefits, plus more.

PostgreSQL is also generally regarded as being a bit more stable, a bit more reliable, scales better for very, very large datasets, and is more standards compliant than MySQL. The PostgreSQL module for SilverStripe was specifically built to take advantage of the various features that PostgreSQL offers. 

The module has built-in support for transactions, extended index support, (such as partial indexes, fill factors and multiple column indexing), table partitions, table spaces, array data types, and most useful of all, tsearch. Tsearch supports stemming, thesauruses, different languages, plus it's a specialised index so it is generally much faster than MySQL's full-text search. All of this is aimed at organisations who have very large databases and want to take advantage of the speed improvements and optimisations that these features offer.

To make using PostgreSQL as painless as possible, we made sure that all you need is the module in your SilverStripe installation and PostgresSQL 8.3+. You can choose your PostgreSQL database via an option on the install screens when you first use SilverStripe. (You can also install it later, if you want.) 

If those of you in the development community are interested in helping to make the PostgreSQL module even better, the best way to do so is to use it and send feedback on any bugs that are found. (Patches are also gratefully accepted.) Thank you.