3 ms·
The piece might have benefited from at least some nods to relational algebra? Years ago I worked on a system that had relations as a convenient in-memory data-
by eru 3y ago
The piece might have benefited from at least some nods to relational algebra?
Years ago I worked on a system that had relations as a convenient in-memory data-structure. The jump in productivity for expressing business logic felt like going from C to Python. Operations like maps and filter and joins etc are very powerful.
(Funny enough, we used a lot of 'relational object mappers', because the other systems we dealt with were more object oriented so we had to translate into our own relational view.)
- marviel 3y agoI think you're right. Probably due for a follow-up post. EDIT: what was the system, by the way?
- eru 3y agoStandard Chartered Bank's in-house Haskell dialect (and supporting libraries). Codd's original paper about how relational databases are more flexible than hierarchical databases applies just as well when comparing relations against key-value stores like Python's dictionaries (or Haskell's Data.Map, or 'normal' ways to structure data in applications, which can be seen as the equivalent of statically typed dictionaries.) See https://www.seas.upenn.edu/~zives/03f/cis550/codd.pdf https://www.seas.upenn.edu/~zives/03f/cis550/codd.pdf
- gpderetta 3y agoYes! I dream of a language were the relational table is the primary data structure.
- eru 3y agoOh, it wasn't a primary data structure, yet alone 'the' primary data structure. It was just provided via a library and very easy to use. Haskell is pretty good about making user-provided libraries as convenient to use as things built into the language.
- ngcazz 3y agoThese are not programming languages per se, but give VDM-SL or Alloy Analyzer a look. I know that particularly in the latter, anything can be joined or composed against anything since all values are relations.