News for hackers. Stuff that matters.
Re:OrmHate by debacle on Tuesday June 26, 2012 @11:28AM (#4162390)
I would agree with you. It's impossible to write a query that can both be composable and also use all of the features of the SQL server's optimizer.
Re:OrmHate by jerf on Tuesday June 26, 2012 @12:34PM (#4162767)
I've done the "kick a design around in my head as I'm driving home" on this problem a few times, and the optimizer is always what ends up stopping me dead. I can create a new query language, I can write the compiler to turn it into an equivalent SQL query, but I have no interest in the monstrosity the language would become if it tried to give you enough control over the resulting SQL to satisfy optimizers. A query language that produces uselessly slow SQL is itself useless, so it's hard to get up the motivation to start a project like this when there's basically no way I can produce something usable.