Postgresql: Re: Pgadmin4 10-beta2 For Mac

Posted on  by admin
  1. Postgres For Mac

I'm assuming from context that you mean MySQL when you wrote 'SQL' First of all Postgres isn't better than MySQL, but it does a few things better. PostgreSQL is more compliant with the SQL standard if that is important to you. MySQL has, at least in the past, done certain unexpected non-standard things that could cause silent turncations and data type changes that could lead to data loss. PostgreSQL is ACID compliant out of the box, whereas MySQL requires the use a of specific data store to get ACID compliance. PostgreSQL and MySQL offer different replication options. Which one is best is dependent on your needs Performance wise they're about the same in aggregate, but differ quite a bit in specific cases. Very simply you can probably say that PostgreSQL is faster for complex queries over large complex data, while MySQL is faster for simpler queries over more homogeneous data, but YMMV big time.

PostgreSQL supports more 'exotic' data types like key-value HSTOREs and indexed JSON data. It also makes it a lot easier to create your own custom data types and indexes if you want to. And related to the above PostgreSQL with PostGIS gives you world class support for storing and querying geometric and geographic data, far beyond what MySQL can offer. Why PostgreSQL is better than SQL?

(Assuming you meant MySQL there, given the later context!) Here's the basic tradeoff, as I see it: - Postgres is much more reliable, featureful and stable. Postgres is more difficult to configure for replication generally. There are better GUI tools available for accessing MySQL.

That's basically it. The actual implementation of Postgres is in my experience so far beyond that of MySQL that it's difficult to make a fair comparison in terms of features, but Postgres still has a bit of catching up to do WRT administration. Basically I can't imagine a situation in which I'd choose to use MySQL, unless it was a prerequisite for some other piece of software.

PostgresqlPostgresql re pgadmin4 10-beta 2 for mac

- Postgres is much more reliable, featureful and stable. Not just that. PostgreSQL also takes care of correctness. This is not to be underestimated, and no MySQL tooling is able to weight this up.

MySQL produces silent data loss on innocent-looking SQL queries, so you have to be absolutely careful even with basic stuff like CONCAT, DATE/TIME formatting or GROUP BY. PostgreSQL throws an error and aborts the transaction whenever you are doing something stupid, so no harm was done and you can simply retry with your corrected query. For me, this is not just an advantage, it is a game changer.

ELI5: PostgreSQL is broad and a bit shallow, while MySQL is narrow and reasonably deep. PostgreSQL has a much broader feature set, but isn't as finely tuned for any given use case. MySQL has a very narrow feature set comparatively, but has deep support for things like replication, backup (fast restores in particular with Percona's tools), and fairly speedy insert and update (doesn't have postgresql's write amplification problem). My tools are psql for PostgreSQL, and mysql for MySQL.

Postgres For Mac

I've never needed anything more; most of my time is spent trying different variants of the same semantic SQL to encourage use of one query plan or another. PostgreSQL has much more strategies available, but the downside is it has a more sophisticated query planner, which means it's less predictable and can start using suboptimal plans as the database statistics change. If my query is complex (e.g. Using window functions or recursive CTEs) I prefer PostgreSQL, if I have a thorny production performance problem, I have more confidence that it'll stay fixed in MySQL. But with recent PostgreSQL supporting parallel operations in the query plan, it has a big weapon to fight back against MySQL's single-threaded queries.