'; DROP TABLE *
Comment on Spent half an hour on it. Felt good.
rtxn@lemmy.world 1 year ago
You wrote an SQL statement?
ZILtoid1991@lemmy.world 1 year ago
flyingSock@feddit.org 1 year ago
Such a sparkly string must be good.
ByteJunk@lemmy.world 1 year ago
What do you mean? That’s a surname.
fulcrummed@lemmy.world 1 year ago
Lil Bobby… there really is an xkcd for everything!
Dave@lemmy.nz 1 year ago
Do people actually write SQL in all caps? Ever since I was a boy I’ve always written SQL (and HTML) in lower case.
PotatoesFall@discuss.tchncs.de 1 year ago
I do it because it helps me visually separate SQL keywords from table and column names.
Helps especially when your SQL is embedded in another file so there is no syntax highlighting.
Dave@lemmy.nz 1 year ago
That’s a good reason. I guess when I’m directly writing SQL the queries are point in time and not part of some enduring codebase.
svc@lemmy.frozeninferno.xyz 1 year ago
YEAH, THAT’S WHY HE PRESSED CAPSLOCK
umbraroze@lemmy.world 1 year ago
SQL is an Old Language of Ancient Power. You have to write the keywords in all caps.
(Fortran is basically the same, but it’s rarer. Lisp is too, but you don’t need to capitalise everything, as the Ancient Power is contained in the parentheses.)
Hupf@feddit.org 1 year ago
xkcd.com/297/
SeboBear@discuss.tchncs.de 1 year ago
This just made my day 😂
cobysev@lemmy.world 1 year ago
They’re both acronyms, so yes? You always write acronyms in upper case.
Structured Query Language (SQL)
HyperText Markup Language (HTML)
Some exceptions to the rule exist, like “Database” is usually abbreviated as Db in acronyms. For instance, IMDb (Internet Movie Database).
Although considering database is a singular word, it makes sense to lower-case the middle letter of the word, as it wouldn’t be capitalized in the spelled-out word anyway.
Dave@lemmy.nz 1 year ago
Not sure if joking but I meant the language not the acronym.
cobysev@lemmy.world 1 year ago
SQL is the language. Its name is also an acronym, for “Structured Query Language.”