3 ms·
It can depend on your perspective. If you look at an app and just see tables and data then yes, model objects stand in a way. If you describe your app as this t
by 3pm 4y ago
It can depend on your perspective. If you look at an app and just see tables and data then yes, model objects stand in a way. If you describe your app as this thing that manipulates the database then I can see how a layer of abstraction can be annoying. But people write 'billing apps' not 'data manipulator apps', so there is this pesky business logic. ORM helps you separate business logic from data access logic. If you don't need this separation then it just stands in the way. ORM is not perfect, but most abstractions leak to some extent.
I think it also depends on how the 'model objects' are implemented. Is it Active Record or Domain Model? I think most of the complaints about ORM are actually complaints about Active Record / DAO, or just a crappy implementation. Also nothing wrong with using SQL in an otherwise ORMed application. Just harder to unit test, refactor etc.