Live data from Hacker News

Why PostgreSQL is better than MySQL

blog.2ndquadrant.com

11–20 of 100 posts

Re: Why PostgreSQL is better than MySQL

#11
post #5
post #3

MySQL is bad because they've tracked a bug across 3 different companies & working groups. Postgres is good because we have no open bug tracker whatsoever and we're always adding new features! I can't figure out who this article is for - certainly not DBAs!

2nd Quadrant is a DBA-as-a-service company that does only Postgres, so it makes sense that the target audience is decision-makers trying to pick between databases who are themselves not DBAs (but probably in the position of hiring DBAs, either as normal employees or as a company to contract with).

FWIW we're not "DBA-as-a-service company". It's part of the job, but we do all sorts of stuff (support, consulting, trainings, custom development, ...)

Re: Why PostgreSQL is better than MySQL

#12
post #6
post #4

Earlier quoted context omitted.

https://wiki.postgresql.org/wiki/Open_Items This seems to be the canonical list.

Wow, this surprises me a lot, especially combined with the consensus position that Postgres is good, robust software. What is Postgres doing right and how can other projects follow their lead?

On a more serious note, what makes Postgres so reliable is a number of things. For example:

* careful patch review process - Sometimes it's a bit grueling, and it takes time to get stuff in, but it's extremely valuable. Not only for finding bugs but alternative approaches to implementing the feature.

* careful testing - It's a natural part of the review process (Does the patch have tests? Can I come up with something weird that makes it fail?). Of course, there's a bunch of machines with very different configurations (OS, hw resources, ...) that are generally quite good in finding race conditions, incorrect assumptions in the code, ...

* bugfixing - Someone reported a bug on pgsql-bugs? Challenge accepted. Customer reported a bug internally? Better fix it ASAP.

Re: Why PostgreSQL is better than MySQL

#14
post #6

Earlier quoted context omitted.

Wow, this surprises me a lot, especially combined with the consensus position that Postgres is good, robust software. What is Postgres doing right and how can other projects follow their lead?

Fix bugs, don't track them.

I'm trying! But sometimes I find two bugs and I can only keep one in my head at a time. What do I do then?

Re: Why PostgreSQL is better than MySQL

#15
This post actually makes me wonder... is there anyone that objectively still thinks MySQL is the better database of the two?

The only small advantage of MySQL I can think of (which is a great downside as well) is that it's really tolerant towards all sorts of erroneous usage and data.

The following should be a problem but are accepted by MySQL

- missing group by clauses

- all of the `ignore` commands (insert, alter table, etc.) - incorrect dates

- not enforcing foreign key constraints

Re: Why PostgreSQL is better than MySQL

#16
Perhaps a better title would have been: "One way in which PostgreSQL is better than MySQL". While I love Postgres, I have to admit that MySQL has its usefulness as well. I just did a side project where I started in node and postgres, realized I needed to hand it over to a guy who would want to end up hosting it on some 5 dollar a month PHP-esque plan. So, I bit the bullet, migrated the DB over to MySQL, and rewrote the backend in Laravel/PHP. It'll do just fine for his usage. My alternative was to host it on DigitalOcean, and then become the IT guy.... or perhaps spin up Heroku... but in the end, I just wanted to pass off a package and be done with it. MySQL was dead simple for my use.

Re: Why PostgreSQL is better than MySQL

#17
post #15

This post actually makes me wonder... is there anyone that objectively still thinks MySQL is the better database of the two? The only small advantage of MySQL I can think of (which is a great downside as well) is that it's really tolerant towards all sorts of erroneous usage and data. The following should be a problem but are accepted by MySQL - missing group by clauses - all of the `ignore` commands (insert, alter t…

Uber switched from Postgres to MySql. https://eng.uber.com/mysql-migration/

If I remember right, though, mostly because their use pattern was more like a key value store, and MySQL worked better for that pattern.

Re: Why PostgreSQL is better than MySQL

#18
post #6

Earlier quoted context omitted.

Wow, this surprises me a lot, especially combined with the consensus position that Postgres is good, robust software. What is Postgres doing right and how can other projects follow their lead?

Fix bugs, don't track them.

That seems like a bit of a false dichotomy. Do the Postgres Devs genuinely see having a bug tracker as a "bad thing"? Or are they just stuck in their ways at this point?

A mailing list hardly seems like an efficient method for tracking bugs unless a major part of the efficiency is reducing signal to noise by make it more difficult for non-developer or non-paying users to file bugs

Re: Why PostgreSQL is better than MySQL

#19
post #6

Earlier quoted context omitted.

Wow, this surprises me a lot, especially combined with the consensus position that Postgres is good, robust software. What is Postgres doing right and how can other projects follow their lead?

On a more serious note, what makes Postgres so reliable is a number of things. For example: * careful patch review process - Sometimes it's a bit grueling, and it takes time to get stuff in, but it's extremely valuable. Not only for finding bugs but alternative approaches to implementing the feature. * careful testing - It's a natural part of the review process (Does the patch have tests? Can I come up with something…

Was Postgres always this way? Was the code from Berkeley abnormally stable/robust for commercial software (and extremely abnormally stable/robust for academic software), or was there an effort to clean it up to get to high quality?

Re: Why PostgreSQL is better than MySQL

#20
post #15

This post actually makes me wonder... is there anyone that objectively still thinks MySQL is the better database of the two? The only small advantage of MySQL I can think of (which is a great downside as well) is that it's really tolerant towards all sorts of erroneous usage and data. The following should be a problem but are accepted by MySQL - missing group by clauses - all of the `ignore` commands (insert, alter t…

Are you sure mysql doesn't enforce foreign key constraints? I recently did a project with mysql backend and it did threw constraint errors on invalid inputs that didn't match a parent key record.
Post reply on HN