• frezik@midwest.social
      link
      fedilink
      arrow-up
      6
      ·
      3 days ago

      There are scripting extensions to SQL that definitely are. There are some features in some SQL servers that make it Turing Complete even without scripting stuff.

      https://stackoverflow.com/questions/900055/is-sql-or-even-tsql-turing-complete

      Like HTML5+CSS3 being Turning Complete, it’s easy to add features that accidentally make you hit the threshold. Many would argue that it’s a sign complexity has run away from you, and I tend to agree.

      • msage@programming.dev
        link
        fedilink
        arrow-up
        3
        ·
        2 days ago

        I fully support promoting CSS to be Turing complete if I never have to touch JS for the UI elements ever again.

    • addie@feddit.uk
      link
      fedilink
      arrow-up
      3
      ·
      3 days ago

      Frezik has a good answer for SQL.

      In theory, Ansible should be used for creating ‘playbooks’ listing the packages and configuration files which are present on a server or collection of servers, and then ‘playing the playbook’ arranges it so that those servers exist and are configured as you specified. You shouldn’t really care how that is achieved; it is declarative.

      However, in practice it has input, output, loops, conditional branching, and the ability to execute subtasks recursively. (In fact, it can quite difficult to stop people from using those features, since ‘declarative’ doesn’t necessarily come easily to everyone, and it makes for very messy config.) I think those are all the features required for Turing equivalence?

      Being able to deploy a whole fleet of servers in a very straightfoward way comes as close to the ‘infinite memory’ requirement as any programming language can get, although you do need basically infinite money to do that on a cloud service.

    • barsoap@lemm.ee
      link
      fedilink
      arrow-up
      2
      ·
      2 days ago

      Pure SQL, as in relational algebra, is LOGSPACE/PTIME. Datalog is PTIME-complete when the program (“query”) is fixed, EXPTIME-hard otherwise.

      It’s all quite tractable, but there’s definitely turing-complete declerative langugages. Not just pretty much every functional language, but also the likes of prolog.