I am having hard time writing same complex queries several times for bit different use cases like with limit, with filter, without limit etc.

I came to know that using ORM we can manage this very well.

Please recommend me a good ORM Library/plugin.

  • check the following link. It seems someone has asked this question. http://stackoverflow.com/questions/108699/good-php-orm-library You cant also check this link : github.com/auraphp/Aura.SqlQuery
    – Mostafa -T
    Oct 13, 2016 at 5:50
  • @Mostafa-T The most reacent answer to that question is about 5 years old! Is whatever they recommend there still relevant? I would expect not. I found that question first and was not satisfied by the answers. May 5, 2017 at 14:50
  • The main libraries are Doctrine and Laravel's Eloquent. Propel was excellent, but the old versions are no longer maintained, and the current major version does not have a stable release yet.
    – halfer
    May 5, 2018 at 22:28

1 Answer 1


Have you looked into the Doctrine Project?

Doctrine2 was inspired by the Java Library Hibernate. It comes with an excellent database abstraction library (DBAL) and a query language called DQL.

They also have some great sidecars like Doctrine Migrations which will look at changes in your data model and generate migration classes for deployment.

Their caching library is used in a load of projects too... their community is all about decoupling code so the components are usable outside of their library.

Doctrine2 is by far one of the most impressive PHP libraries around today.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.