Get the latest tech news
Advent of Code 2024 in pure SQL
A blog by and for database architects.
As a consequence you need a machine with over 200GB memory to execute that query, even though most of the computed tuples are irrelevant. We could fix that excessive memory consumption by using iteration semantic during recursion, but that is not widely supported by DBMSes. With just a bit extra functionality SQL would be quite a solid choice for running complex algorithms directly inside a database.
Or read this on Hacker News