3 ms·
> My issue with SQL is that a programming language should allow you to compose and name building blocks, and then recombine them to build ever more useful softw
by collyw 8y ago
> My issue with SQL is that a programming language should allow you to compose and name building blocks, and then recombine them to build ever more useful software.
When I write a complex query it's kind of like this.
I start with one table (viewed in my head as an excel style grid of results). I join another table then filter on the join / where clause. Again the output is effectively another table. Rinse repeat.
The difference is that SQL is very powerful at what it does, so you don't need to compose blocks in the way that you would in other languages. Just think of everything as a table. The result of every join or filtering clause is another table. That's your building block.
You are going to need significantly less SQL than Java / Python to get the same results from your data.