What's your favorite construct in SQL?

3 years ago by megaman1970 to c/programming

For me, it's CTE's. I find it amazing to complete a calculation with clear intermediate steps, and goes a long way towards convincing people to use SQL rather than Excel to perform calculations on large tables of data.

What construct do you like using on a daily basis?

load all comments
szeis4cookie 3 points 3 years ago

I was skeptical of CTEs for a long time. I just used subqueries when I could in T SQL, and then I got a new job and my new company used Postgres. In the adaptation process I took a new look at CTEs and became a convert - it's just nicer and easier to read the intermediate step than as a subquery

path: 0 111210, hotness: undefined, score: 3, children: 0
programming
programming

@beehaw.org

login for more options
3347
186
1

All things programming and coding related. Subcommunity of Technology.


This community's icon was made by Aaron Schneider, under the CC-BY-NC-SA 4.0 license.

go to feed...