Live data from Hacker News

Why you should learn SQL

executeprogram.com

51–60 of 137 posts

Re: Why you should learn SQL

#51
I just keep getting faster at SQL. It's fun. I used CROSS LATERAL JOIN last night to find the nearest regions to points. Super fast and easy: https://carto.com/blog/lateral-joins/. Right on the data. SQL does change over time, as Postgres adds features, but especially when you use MADlib, Postgis, and other extensions. I mean ... https://postgis.net/docs/reference.html. And everything I learned when I started is still relevant. It's my go-to crunch tool for data processing.

Re: Why you should learn SQL

#52

SQL is going to eventually die because of its three-pronged relationship model that implies query-time complexity. Learn it if you want, but especially backend and analytics people would be better off learning Gremlin or Cypher. Edit: downvoting this is not going to make it untrue.

You're getting downvoted most probably because your comment provides no arguments why. Why would I be better off with Gremlin or Cypher?

Re: Why you should learn SQL

#54
I used to love ORM, I used it everywhere. Writing another language in the language I am coding is wrong. ORM simplifies my programs.

No, ORM does not simplify coding! It's a big complex adapter which does not fit many cases.

RDBM itself is complex enough, let's put another complex abstraction above it so we can forget about the tables and columns and joins and foreign keys. Complexity added upon another complexity does not make a polished interface.

If you want to use ORM, you have to learn both SQL and ORM with some depth at least. When problems occur, you have to debug both.

20 years in, I am still learning about RDBM. I still hate to compose SQL in code, but there is no better way.

Databases are used in every situation. Want to store data? Database. Want to communicate between processes? Database. Want to store logs? Database. There are different solutions for different scenarios, but as long as the DB chugs along, why? Sometimes it's sickening.

So 20 years in, the ROI of learning SQL is great. Please don't avoid learning about RDBM by using an ORM. Just learn it.

Actually, I'm not without ORM now a days. Light-weight ORM like Dapper serves well, it does not abstract out the concepts of RDBM, but make things easier.

Re: Why you should learn SQL

#55

> The SQL langauge is old, strange, and important. I've always found it strange that something hasn't replace SQL, particularly for traditional 'web' client/server applications. But SQL is probably the only technology/language that has survived in the past 30 years of my career. 99% of their SQL databases probably don't require transactions and ACID behaviour. There nearly always needs to be a layer to convert the ro…

Over 90% of the projects I have been involved in have required ACID. In fact I can't think of any that used a database and did not require ACID so I think your 99% should be inverted: 99% of all databases require ACID. This is evident from how even MonogoDB is ACID now with their new storage engine.

Re: Why you should learn SQL

#57

At times it might make sense not to use SQL. That is fine. But I think there is a value in learning SQL. Some reasons: * Learning effort to Reward ratio is good. A substantial syntax is valid for all of the DBs that support SQL. * Very easy to remember the syntax. I have not used SQL in a long time but I can still write one without much effort (including the nested queries) * Pareto: About 70-80% of data retrieval us…

Or Idea Ultimate which contains Datagrip's functionality and the other languages they made IDEs for, except CLion (C/++, Rust debugger) and Rider (C/F#). Android Studio can connect to the Apps SQLite db. There is a plugin for Vim to connect to DBs, Written by Tim Pope.

Just a content user.

(edit) Links for the curious:

https://github.com/tpope/vim-dadbod

There are a UI and completions for it too:

https://github.com/kristijanhusak/vim-dadbod-ui

https://github.com/kristijanhusak/vim-dadbod-completion

Re: Why you should learn SQL

#58

We're currently moving our Druid/Kafka/Spark setup to BigQuery because of how simple SQL is.

My employer is going to the other way from snowflake -> druid to reduce high response latencies/ improve freshness.

I am assuming your use cases can tolerate increased latency?

Re: Why you should learn SQL

#59
post #52

SQL is going to eventually die because of its three-pronged relationship model that implies query-time complexity. Learn it if you want, but especially backend and analytics people would be better off learning Gremlin or Cypher. Edit: downvoting this is not going to make it untrue.

You're getting downvoted most probably because your comment provides no arguments why. Why would I be better off with Gremlin or Cypher?

Because it eliminates the complexity of joins: both the mind-complexity and the algorithmic complexity.

Re: Why you should learn SQL

#60

I've spent most of my career hoping that something - anything that's better than SQL will come along and replace it. It's like FORTRAN, except FORTRAN has had the decency to stay in use where it's really the best choice. But SQL is out there, like Clippy. "Hey, I see you're collecting some data. SELECT TRUE FROM HELP WHERE COLLECTING_DATA IS TRUE

EdgeQL looks promising https://www.edgedb.com/docs/edgeql/overview
Post reply on HN