Doctrine_Recordisthebasiccomponentofeverydoctrine-basedproject.ThereshouldbeatleastoneDoctrine_Recordforeachofyourdatabasetables.Doctrine_Recordfollowsthe[http://www.martinfowler.com/eaaCatalog/activeRecord.htmlActiveRecordpattern]Doctrineauto-createsdatabasetablesandalwaysaddsaprimarykeycolumnnamed'id'totablesthatdoesn't have any primary keys specified. Only thing you need to for creating database tables is defining a class which extends Doctrine_Record and setting a setTableDefinition method with hasColumn() method calls.An short example:We want to create a database table called 'user' with columns id(primary key), name, username, password and created. Provided that you have already installed Doctrine these few lines of code are all you need:<code type='php'>require_once('lib/Doctrine.php');spl_autoload_register(array('Doctrine', 'autoload'));class User extends Doctrine_Record { public function setTableDefinition() { // set 'user' table columns, note that // id column is always auto-created $this->hasColumn('name','string',30); $this->hasColumn('username','string',20); $this->hasColumn('password','string',16); $this->hasColumn('created','integer',11);}}</code>WenowhaveausermodelthatsupportsbasicCRUDopperations!