Skip to main content


Okay, I'll admit it. Using #Haskell to talk to an #SQL database is not my favourite thing.

Programming Feed reshared this.

in reply to Jonathan Lamothe

I was also negatively surprised. What library did you choose in the end and what database?
in reply to Philipp :emacs: :nixos:

@Philipp :emacs: :nixos:
Hasn't been fully decided yet. I'm presently working with an SQLite database, though it's already migrated from LibreOffice Base (don't ask).

I'm trying to build a nice front-end on it so my wife can use it without having to learn SQL. I've worked with persistent-sqlite before because of yesod, but setting it up as a standalone thing is a pain, and it really irks me that I need a whole separate library (esqueleto) just to do joins. I mean, isn't that the whole point of SQL in the first place?

Side note: I kept responding to the wrong post.

in reply to Jonathan Lamothe

I hear talking to PostgreSQL can be enjoyable.

But, I fear there will always be issues with partiality and overlaps when modeling sum (or Pi!) types in SQL.

$dayjob is still just composing and running untyped, unstructured "SQL", but we are also still talking to MS SQL which is well-known to be unfriendly even compared to other SQL DBs.

in reply to Boyd Stephen Smith Jr.

@Boyd Stephen Smith Jr. It's not so much the SQL part that's the irritating bit. It's that it doesn't really mesh super well with "the Haskell way of doing things".
in reply to Jonathan Lamothe

@BoydStephenSmithJr understandable. There's always a tension between "pleasant for the Haskeller" and "pleasant for the DBA" (or general SQL knower). We have the same problem at work (we sacrificed our DBA and used flora.pm/packages/@hackage/hpq… and its eDSL)

This website uses cookies. If you continue browsing this website, you agree to the usage of cookies.