Macaque (Macros for Caml Queries) is a DSL for OCaml, wich produce SQL requests from a comprehension syntax. Macaque can build queries by from simpler components, using phantom types used to ensure safety.
Development version
Macaque is still quite young, and no stable version has been released yet.
Interested users are however strongly encouraged to look at the
current state of affairs (wich is certainly usable) and report any
issue or feature need.