2 ms·
This is one of my beefs with ORM -- in order to use the database layer properly, you need to expose at least as much complexity as the database itself provides.
by jfb 16y ago
This is one of my beefs with ORM -- in order to use the database layer properly, you need to expose at least as much complexity as the database itself provides. We use Sequel, which is fine as far as it goes, but it ships with a stupid DSL that is a) as complex as SQL and b) significantly less capable. You end up with shitass queries and many more database round trips and for what? Method call syntax?
Sorry. Rant.
- jarin 16y agoSpeed of development. I know perfectly well how to write SQL, but I would rather write "Post.where(:published => true).first.comments.count" and move on to the next thing. If I need to later on I can go back and write a raw SQL query, but why do it unless I need to?