Answer the question
In order to leave comments, you need to log in
When are ActiveRecord or Doctrine used?
When are ActiveRecord or Doctrine used? Is the usual use of a PDO wrapper starting to be considered bad manners?
Answer the question
In order to leave comments, you need to log in
Is the usual use of a PDO wrapper starting to be considered bad manners?Starts? In the last century (when there was no PDO yet) it was already considered.
It makes sense to use ActiveRecord if your model fits well with a relational data structure. Those. class properties correspond to table fields.
For complex business logic, a doctrine is better, it maps data from tables to our domain objects and the structure of subd tables can be very different from the structure of our model. The doctrine also includes many great things such as UnitOfWork, EntityManager and a bunch of other handy things.
For most sites and simple projects, active record is a good option. For complex projects - Doctrine.
OnYourLips answered above about using orm vs pdo
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question