ernie/squeel — Issue #69: Squeel-like DSL for general SQL?
Author: jaylevitt
Created: 2011-10-21 17:41:36+00:00
State: open

(Sorry, Ernie - since there's no mailing list, I am hijacking your issues tracker...)

Squeel has made me want to never write monolithic SQL queries again. I want small, composable methods that still end up inlined in a single, performant query. Squeel lets me do that for ActiveRecord models, but I have some user-defined functions and views that don't act upon models, and so Arel can't know about them.

People in the SQL world are just used to writing big convoluted nested queries, and that's life. They don't ask "How can I make this modular?" because that's just not how you do it. But people who use Squeel know what I'm talking about.. is there something like Squeel (or some moral equivalent to CoffeeScript) for SQL? I'm on Postgres, if it matters.