2010-11-20 7 views

답변

0

여기에 샘플 테이블 정의 당신을 도울 것입니다 :)

class typetable extends Doctrine_Record 
{ 
public function setTableDefinition() 
{ 
    $this->setTableName('your table name '); 
    $this->hasColumn('type_code', 'integer', 8, array('type' => 'integer', 
    'length' => 8, 'primary' => true, 'autoincrement' => true)); 
    $this->hasColumn('type_name', 'string', 255, array('type' => 
    'string', 'length' => 255)); 
} 
///// extra code here ...... 
} 
+0

덕분에, 나는 기본 키는 방법 "setTableDefinition"로 설정해야한다, 또는 교리는 기본적은 "ID"를 설정합니다 것으로 나타났습니다. – user514340

관련 문제