top | item 42860559

(no title)

r1b | 1 year ago

Nodding along furiously. One area where this comes up is when you want to export some piece of logic that effectively “returns a table”.

For example, I work with a source of data that requires a particularly hairy JOIN strategy. The logic is the same for any table with the same “shape”, but no one can reuse it without copy / paste.

discuss

order

virtualwhys|1 year ago

See Esqueleto in Haskell, Slick and Quill in Scala, probably LINQ or some variant on .NET in C#/F#.

All support building up arbitrarily complex queries based on statically typed query fragments.

String fragment "composition" is like banging rocks together.