tags:

views:

939

answers:

8

What is the simplest ORM implementation around for PHP? I'm looking for something really simple and light (in terms of LOC, since speed it's not crucial I don't need caches and what not), preferably a single file or class package that doesn't depends on XML or other configuration files and it's easy to deploy.

Reading other similar questions Pork.dbObject (which by the way is developed by one of SO users) was the closest I could find so far, and I'm interested in knowing if there are any other ORM implementations that might be lighter than this one.

+1  A: 

I've used CoughPHP in the past and been pretty happy with it's simplicity.

Bob Somers
Not exactly what I'm looking for.
Alix Axel
A: 

Ive just started to use Zend Framework and im pretty happy with it.

MANCHUCK
Still a lot bigger than Pork.dbObject.
Alix Axel
A: 

http://www.doctrine-project.org/ is a pretty good, out-of-the box solution.

GSto
doctrine is **not** light.
Alix Axel
A: 

i second Doctrine... Propel is quite good too..

Yash
Both of them are quite heavy.
Alix Axel
+4  A: 

Doctrine and Propel are good, but can't say they are "simplest". Here two alternatives - PHP Active Record , Outlet PHP ORM

Hope one of them helps

Balchev
+3  A: 

I used ADODB Active Record: http://phplens.com/lens/adodb/docs-active-record.htm, it isn't too heavy.

Then again, if you want to make a light one, why not build your own?

JonB
A: 

Why not try plain vanilla PDO (or mysqli if you work with MySQL and don't like PDO)? It's not exactly a full-blown ORM, but it allows fetching query results directly into an object. And it doesn't get any more simple, lightweight and zero-configuration than that. :)

Vilx-
A: 

For a lightweight solution, phpDataMapper might be a good choice.

Vance Lucas