Earlier quoted context omitted.
Parameterized queries are to prevent injection. They don't tell you, at compile time, when you're building an invalid/unrepresentable SQL query.
> They don't tell you, at compile time, when you're building an invalid/unrepresentable SQL query. Sure they do, with a proper library. Haskell's persistent library does this very well.
delete $ from $ \t -> do
where_ $ (t ^. TutorialAuthor) ==.
(sub_select $ from $ \a -> do
where_ (a ^. AuthorEmail ==. val "anne@example.com")
return (a ^. AuthorId)){-/hi-}
tuts do
where_ (t ^. TutorialSchool !=. val True)
return (t ^. TutorialTitle)
looks a lot like something you might get with a good ORM. It might be more general and slightly different, but haskell usually does things slightly different.