top | item 42860615

(no title)

froderick | 1 year ago

I already have functors, effectively, by writing sql queries in clojure with honeysql. The clojure data structures make behavior composition from reusable sql snippets easy, and the testing of sql snippets is just based on literals as the article describes. Works really well.

discuss

order

nateroling|1 year ago

I’ve done the same with SQLAlchemy in Python and SQLKata in C#.

Sadly the whole idea of composable query builders seems to have fallen out of fashion.

jaza|1 year ago

If composable query builders have fallen out of fashion, that's news to me. I've used SQLAlchemy in Python fairly heavily over the years, it's gotta be one of the best out there, I plan to continue using it for many more years. And I've recently gotten my feet wet with Ecto in Elixir, I'm quite impressed with it too.