• @rtxn
    link
    833 days ago

    You wrote an SQL statement?

    • @[email protected]
      link
      fedilink
      193 days 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.

      • @[email protected]
        link
        fedilink
        283 days 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.

        • @[email protected]
          link
          fedilink
          53 days 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.

      • @umbraroze
        link
        152 days 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.)

      • cobysev
        link
        English
        2
        edit-2
        3 days 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.

        EDIT: On a related note (and one that will really show my age), I always capitalize the i in “Internet.”

        When I was a kid, and before the Internet was publicly accessible, we referred to a collection of internetworked computers as an “internet.”

        Then the “World Wide Web” (WWW) became a big deal in the mid-'90s, which was the first publicly accessible internet of computers and servers. It was super primitive and took like 10 minutes just to load a small image on a mostly-text webpage. We referred to this new global internet as “The Internet.” This was the biggest and most ambitious attempt at building an interconnected series of computers, so we called it The Internet (capital “i”) to differentiate it from a regular internet.

        Fast forward several decades… for so long, the Internet has been such a commonly used term to refer to the World Wide Web. It’s completely taken over the word; we don’t really refer to small computer networks as internets anymore. So there’s no point in differentiating between the two.

        But I remember, and I still keep up the old habit of capitalizing when I’m referring to THE Internet, versus a smaller network of computers.

          • cobysev
            link
            English
            -73 days ago

            SQL is the language. Its name is also an acronym, for “Structured Query Language.”

            • @[email protected]
              link
              fedilink
              83 days ago

              More specifically I meant when I am writing in the language.

              I don’t write “SELECT * FROM users;”, I write “select * from users;”

              • @ByteJunk
                link
                23 days ago

                Is your caps lock broken? What the heck is that second select?