ORM for PHP like .NET Entity Framework

11,781

Solution 1

I'd recommend you take a look at Doctrine ORM. Doctrine can generate your table to PHP class mappings using YAML, which is similar to NHibernate's mappings using XML. Doctrine also provides command line tools to rebuild aspects of your data layer based on changes to either your schema, the models themselves or the database tables you're abstracting over.

I've only really looked at NHibernate, not used it. So I wouldn't claim to know precisely how well the two ORMs approaches cross-over; I'm sure a quick glance through their documentation would help you reach a better conclusion.

Solution 2

A good alternative that implements a modern data persistence approach in PHP can be found in Agile Data. It used to be part of Agile Toolkit (http://www.agiletoolkit.org), but now it's refactored into a stand-alone framework.

Share:
11,781

Related videos on Youtube

Jalal
Author by

Jalal

My Blog: https://jalalamini.ir/

Updated on June 04, 2022

Comments

  • Jalal
    Jalal almost 2 years

    I'm a .NET developer and new in PHP. I want to know, is there a ORM for PHP like the Entity Framework in the Microsoft .NET Framework?

    Are there any utility applications to make working with data faster and easier?

  • dynamic
    dynamic about 13 years
    wow from the documentation this seems a beast
  • Jalal
    Jalal about 13 years
    hmm? seems choice is hard :-?
  • Anuj Pandey
    Anuj Pandey about 11 years
    sarcasm ? or really.. Its not loading for me.

Related