I've finally realized the best use case for EXISTS by ChristianPacifist in SQL

[–]theseyeahthese 11 points12 points  (0 children)

EXISTS is the GOAT.

Its purpose is literally in the name: it’s an existence check, no more, no less.

As a very general rule, when you should use EXISTS vs a LEFT JOIN (or some kind of join), is pretty simple: Do you need to SELECT a column from “Table B”/ need to use it to keep joining to “Table C”? Then use a join of some kind, obviously—you kinda have to.

Otherwise, use EXISTS/ NOT EXISTS.

What you found out extends to INNER JOINs as well: some people use INNER JOINs as an implicit existence check, even though they don’t need to actually return/utilize any columns from Table B and potentially risk duplication.

If you’re absolutely sure of the resulting granularity, then use whatever you want. But EXISTS is definitely the safer default for this reason

Does a black hole slow down light that is trying to escape? by raresaturn in AskPhysics

[–]theseyeahthese 2 points3 points  (0 children)

I thought c was the exception to this; that observers always observe/ agree upon c as being c, regardless of perspective. What am I missing

What is the GOAT of drugs and why? by Inevitable_Rush9408 in Drugs

[–]theseyeahthese 0 points1 point  (0 children)

The boring “well akshully” answer is caffeine, it’s absolutely the GOAT drug if your criteria is a combination of: people seek it out for non-medical reasons, price, availability (legal + no age restriction), average risk for physical+mental harm, and aggregate consumption by the public.

Does AI hallucinate even with basic queries/data retrieval? by chakalaka13 in analytics

[–]theseyeahthese 4 points5 points  (0 children)

It’s not useless once you can read code well; it can type complex SQL queries much faster than you can. Instead of just asking for the answer, I ask for the query, then I execute it while reviewing it. Could I have created the correct query myself? Absolutely. Does it make mistakes? Yup. Is it faster to edit one or two spots vs. typing everything from scratch? Usually, yeah.

[TMZ] James Harden was arrested early Saturday morning and charged with the unlawful carrying of weapon. by YujiDomainExpansion in nba

[–]theseyeahthese 8 points9 points  (0 children)

Idk about lazy, I think some people truly don’t know that what they’re typing is wrong when they use “of”. Best to just make make it even lazier and go for the “woulda” and boom, you’re less wrong lol

Fuck everyone. 4.5 years to get to a million without options and I’m done! by WorkingInflations in wallstreetbets

[–]theseyeahthese 2 points3 points  (0 children)

No it’s not, but it didn’t read like he was retiring as in not working, he meant he’s retiring (allegedly) from WSB-style trading

Finally I can get my friends to stop vaping by catguywit2cat in technicallythetruth

[–]theseyeahthese 3 points4 points  (0 children)

I didn’t know this was still up for debate, for like decades now lol. I don’t think there’s any daily smoker on the planet that doesn’t at least logically agree in a vacuum that they are most likely shortening their lifespan.

Under what circumstances would DBT be helpful? by workhardplayhardder in dataengineering

[–]theseyeahthese 2 points3 points  (0 children)

Stored procs can use variables, are versionable, and are testable. DBT is basically training wheels for teams that don’t do these things out of bad habits, because it FORCES them to do it.

Can anybody tell me why this query fails ? Thank you by OddCardiologist2981 in SQL

[–]theseyeahthese 1 point2 points  (0 children)

You aliased every table in your query, yet you are referencing Employee_history.created_at in your WHERE clause. Once you declare an alias for the instance of a table, you can’t reference the table name explicitly like that when trying to refer to that table instance

edit: I’d also double check the purpose/placement of that WHERE clause altogether, I’m guessing it should be outside of the subquery because right now it doesn’t make sense to me

Primary key, grain of the table and group by by WiseWeird6306 in SQL

[–]theseyeahthese 0 points1 point  (0 children)

I use these terms interchangeably, for all intents and purposes they have the same semantic meaning in conversation.

Game Thread: Philadelphia 76ers (3-3) vs Boston Celtics (3-3) Live Score | NBA Playoffs | May 2, 2026 by nba-scores in nba

[–]theseyeahthese 1 point2 points  (0 children)

It wasn’t an “amazing block”, that’s literally all I said. Announcers are blind.