Live data from Hacker News

Postgres 11 – A First Look

craigkerstiens.com

51–60 of 193 posts

Re: Postgres 11 – A First Look

#51
post #37

A million things like this are why PostgreSQL is the only relational database I consider for, well, pretty much anything. Their approach of “build it safe and then make it fast” has been paying off in spades for a couple of decades now. Thanks for everything you do, psql maintainers!

100% naive question: why is mysql and their similars so popular then? Spanner and AWS Aurora base off of more mysql than postregsql from what I can tell. Why?

History. A long time ago, in the early 90s, there was a database called msql. It was a little DB that used SQL and ran well on low end systems. It was also free. In fact, it was the ONLY free SQL database out at the time -- that's why it was written.

Because of those two advantages (that really only lasted a couple of years), a small ecosystem developed around it. This was the database you used to develop interactive websites in the early/mid-90s.

Then MySQL came. MySQL extended mSQL, and kept compatibility with it's ecosystem... and people switched from mSQL to MySQL.

Postgres also existed in the 80s and 90s, but it used POSTQUEL, was harder to setup, and had higher system requirements. Not a lot, but enough to discourage use on low end computers. (Remember, Postgres at the time was being developed on university servers, where they had plenty of system resources.)

They did address these points in postgre95 (in fact, Postgres adopted SQL as a response to mSQL popularity), but by then it was too late. mSQL and MySQL already had an ecosystem.. and in that brief moment, they lost the race.

The idea that it was slower stuck around for many years, even after the improvements in computers, and (less so) optimizations in Postgres made it no longer true.

Postgres didn't start being considered again until Go, RoR, et al started to become popular.. displacing the PHP ecosystem. And the biggest reason you see MySQL around so much today is that there's about 25 years of legacy code built around it.

Edit: If you're curious what POSTQUEL was like: https://en.wikipedia.org/wiki/QUEL_query_languages

Re: Postgres 11 – A First Look

#52
post #37

A million things like this are why PostgreSQL is the only relational database I consider for, well, pretty much anything. Their approach of “build it safe and then make it fast” has been paying off in spades for a couple of decades now. Thanks for everything you do, psql maintainers!

100% naive question: why is mysql and their similars so popular then? Spanner and AWS Aurora base off of more mysql than postregsql from what I can tell. Why?

I’m no expert on this topic and have used both PG and MySQL.

My preference is MySQL purely because the syntax is easier, or at least consistent with what I learned at uni in the late ‘90s.

I also like MySQL workbench, although I’m sure there is an equivalent for PG I haven’t needed to look for one in recent years.

If PG allowed me to use the same syntax as MySQL I’d probably switch, purely because experts and those with more experience than I generally prefer PG for a whole lot of reasons.

EDIT: I should have googled first before replying. Looks like the syntax is near enough to identical for my simple needs and pgadmin will do what I need. I’m not sure why I had to learn some other weird syntax in 2012 for postgres, perhaps it was just shortcuts. Either way I’m going to seriously consider migrating now. :)

Re: Postgres 11 – A First Look

#53
post #37

A million things like this are why PostgreSQL is the only relational database I consider for, well, pretty much anything. Their approach of “build it safe and then make it fast” has been paying off in spades for a couple of decades now. Thanks for everything you do, psql maintainers!

100% naive question: why is mysql and their similars so popular then? Spanner and AWS Aurora base off of more mysql than postregsql from what I can tell. Why?

> Why?

Notice that parallel to MySQL's rise a particular loosely-typed, never-except, often-wrong programming language also became popular. To this day I feed my family with that language.

The typical coder (not that I do not say "developer") who codes in PHP does not care about correctness. He does not understand why monetary values cannot be stored in floats, he does not know what bitwise manipulation is, he does not know the difference between character encodings. What does he care what MySQL does, he knows that he can put strings in if he calls them VARCHAR, and he can pull the right one out with a WHERE. He cares not enough to check that user bios fit in his VARCHAR, and when he learns to JOIN he does not understand which constraints to put in the ON clause.

I do have nicer words for the L and A in the stack.

Re: Postgres 11 – A First Look

#54
post #3

> Now you can quit Postgres by simply typing quit or exit. Previously you had to use Ctrl + D or \q While this is good to help out beginners a bit, people should really learn Ctrl + D. It works practically everywhere and saves tons of time guessing/remembering and even typing the correct incantation for the program you want to exit.

What does Python do these days? I seem to remember it would catch common cases, but rather than quit, scold you and tell you how you should be doing it the other way, which seemed like the most Western European approach imaginable.

Re: Postgres 11 – A First Look

#55
post #52
post #37

Earlier quoted context omitted.

100% naive question: why is mysql and their similars so popular then? Spanner and AWS Aurora base off of more mysql than postregsql from what I can tell. Why?

I’m no expert on this topic and have used both PG and MySQL. My preference is MySQL purely because the syntax is easier, or at least consistent with what I learned at uni in the late ‘90s. I also like MySQL workbench, although I’m sure there is an equivalent for PG I haven’t needed to look for one in recent years. If PG allowed me to use the same syntax as MySQL I’d probably switch, purely because experts and those w…

What syntax do you have in mind? Can you give sone example of what you see as easier in MySQL than Postgres? Genuinely curious, I don't have money in that game

Re: Postgres 11 – A First Look

#56
post #37

A million things like this are why PostgreSQL is the only relational database I consider for, well, pretty much anything. Their approach of “build it safe and then make it fast” has been paying off in spades for a couple of decades now. Thanks for everything you do, psql maintainers!

100% naive question: why is mysql and their similars so popular then? Spanner and AWS Aurora base off of more mysql than postregsql from what I can tell. Why?

I used both of them, but migrated to Postgres permanently a decade ago.

Early on in my career, the biggest selling point for Mysql was the excellent web admin tool "phpMyAdmin" - it really helped get applications off the ground, since the core of most modern systems is the data model. Users could modify data, without your needing to create a UI for that use case.

It conveniently used the same stack as the rest of the software, but I remember spinning up a phpMyAdmin instance even after moving away from PHP as an application language.

Postgres still doesn't really have anything like that! The closest that comes to mind is Django's Admin tool.

Re: Postgres 11 – A First Look

#58
post #55
post #52

Earlier quoted context omitted.

I’m no expert on this topic and have used both PG and MySQL. My preference is MySQL purely because the syntax is easier, or at least consistent with what I learned at uni in the late ‘90s. I also like MySQL workbench, although I’m sure there is an equivalent for PG I haven’t needed to look for one in recent years. If PG allowed me to use the same syntax as MySQL I’d probably switch, purely because experts and those w…

What syntax do you have in mind? Can you give sone example of what you see as easier in MySQL than Postgres? Genuinely curious, I don't have money in that game

I recall having to type /d from the command prompt to show databases (or something like that). I prefer “show databases”.

Re: Postgres 11 – A First Look

#59
post #34

Earlier quoted context omitted.

You use the word intuitive a couple of times, and suggest there's a natural way to exit interactive cli programs (and it's not ctrl-d). Yet for me, ctrl-d is my usual first way of trying to exit any shell or cli utility. Whether it's natural or not, I couldn't say. Arguably the nipple is the first and only intuitive interface, everything after that is learned. After many years on my/maria I find the backslash shortcu…

CTRL+D works. You like it. Great use that. You don't think anybody needs an alternative? Or you don't think having an alternative will help at all? Fine. Think what you want. One thing's for (mostly) certain: it doesn't hurt. So there's really nothing to complain about.

> CTRL+D works. You like it. Great use that. You don't think anybody needs an alternative? Or you don't think having an alternative will help at all? Fine. Think what you want. One thing's for (mostly) certain: it doesn't hurt. So there's really nothing to complain about.

Not complaining about its presence, as per my comment :

"While I think it's great to have both options present,..."

Just observing that claims of 'more intuitive' interfaces are very subjective, and that it was unlikely to be a deal breaker for a new user.

Re: Postgres 11 – A First Look

#60
post #46
post #37

Earlier quoted context omitted.

100% naive question: why is mysql and their similars so popular then? Spanner and AWS Aurora base off of more mysql than postregsql from what I can tell. Why?

MySQL used to be more popular. It was the M in the LAMP stack, which virtually everyone used to use. It also used to be more scalable, because PG's replication story used to be poor. This is why Google and (I assume) Amazon used MySQL internally. This is all a long time ago, but I suspect this is the reason more people are familiar with MySQL than Postgres at these companies. Keep in mind that Spanner was developed a…

> This is why Google and (I assume) Amazon used MySQL internally.

Amazon actually uses a lot of Oracle with some scattering of MySQL.

Post reply on HN