top | item 33038281

(no title)

omegalulw | 3 years ago

You are selling SQL way short. SQL has stuck around because, compared to its complexity, it lets you do incredibly powerful things.

discuss

order

strbean|3 years ago

Look at the analogy to general purpose programming languages.

Every single one, without exception, lets you do incredibly powerful things compared to its complexity.

This hasn't stopped the progression of general purpose programming languages, and I think the vast majority of developers would agree that there have been huge improvements in the last 50 years.

doctor_eval|3 years ago

TIOBE [0] reckons that the top 10 programming languages are currently Python, C, Java, C++, C#, Visual Basic, JavaScript, "Assembly Language", SQL and PHP. The first five languages represent more than 50% of the users in TIOBE.

Apart from SQL, all of these languages are imperative, and most of them derive from C in some shape or form; K&R C was published in 1978, 44 years ago.

So, while I'd agree that there have certainly been huge incremental improvements in imperative programming in the last ~50 years, when we look at what people use on a daily basis, it's not really clear to me that the changes have been any greater in significance than the changes that SQL has gone through during the same period.

[0] https://www.tiobe.com/tiobe-index/

patmorgan23|3 years ago

But aren't most people using ORM's? In which case the SQL code is more like a kind of byte code. SQL definitely is supper powerful, but it's also embedded deeply in all of the RDBMS's and tooling around them etc.

Lots of stuff untilizing SQL and the ability to do lots of cool stuff with SQL, doesn't actually mean that the Developer Experience or ergonomics around using SQL are good.

duxup|3 years ago

It's also great that much of the time if I come up with a crappy query... SQL knows how to optimize it for me. Easy to use, and fixes my stupids.

OJFord|3 years ago

That's nothing to do with SQL, that's the database engine you're using (lexing, parsing, then) planning & optimising your query as best it can.

Much like C code say, it's not a feature of C the language that gcc, for example, can optimise your crappy code for whatever target platform.