3 ms·
PostgreSQL vs MySQL (and to lesser extent also compared with MSSQL and Oracle)
I know this is subjective to how/where you use it but am wondering what people who have used PosgreSQL think about it.
I see that the newer version match MySQL in speed while retaining better data integrity (and in many cases PGSQL is actually faster in both default install & after optimisations).
I want to build some web apps (ideally in Ruby On Rails and some in Django) and want something that scales better and is more robust.
Thoughts, comments, experiences and insights appreciated.
Basic overview @ http://is.gd/d5l gives some good intial pointers but needs more real world experiences to be added.
Thanks.
- epi0Bauqu 18y agoI have lots of experience with Postgres (including scaling somewhat from a web app perspective) and have nothing really bad to say about it. It scaled well. The key (at least for me) is to make sure indexes are in memory, which I think will be the case no matter what DB you use.
- e1ven 18y agoHave you used server-clustering with pgsql? Slony doesn't do multi-master, and requires manual failover; I understand the technical reasons for this (The slave may not be up to date, so data will be lost, etc), but we're looking for other options. pg_cluster and it's ilk seem under tested, but I'd be VERY interested in your experiences, if any. Clustering under mysql has always been fairly trivial, so it'd be nice to find a decent solution.
- babul 18y agoI would be interested to hear about this too.
- epi0Bauqu 18y agoI have found that the situations you really need clustering are few and far between in the world of web apps. We had over 20M users and we're running fine on one 2U database server. It had 6 disks (RAID 5, with two hot spares) and 16GB of memory. The indexes all fit in memory. The acquiring company of our business immediately decided they wanted more hardware for clustering, and set up Slony. I was semi-involved in it, and I witnessed no problems. On a bigger scale, I understand that skype uses pgsql and obviously does clustering: https://developer.skype.com/SkypeGarage/DbProjects/SkypePostgresqlWhitepaper https://developer.skype.com/SkypeGarage/DbProjects/SkypePost... Also check out http://highscalability.com/postgresql-high-availability-websites http://highscalability.com/postgresql-high-availability-webs... and http://highscalability.com/skype-plans-postgresql-scale-1-billion-users http://highscalability.com/skype-plans-postgresql-scale-1-bi...
- SwellJoe 18y agoI will tell you all you need to know in three (run on) sentences: PostgreSQL is historically a more complete and reliable SQL database, that was once slower than MySQL but is now slightly faster for most workloads. Either database will probably work great for anything you will ever need from them--if you are running into scaling problems for a site that we've never heard of (I assume we've never heard of it) you're probably doing something pathological. Google uses MySQL heavily, so despite its many historical problems, if you grow big enough to run into them, you will figure out a way to solve them and in some cases you will cause them to be solved for the general MySQL userbase, as Google has done.