/** * Run insert */ private function runInsert() { if (!is_null($this->Prepared)) { $this->runPreparedInsert(); } else { $this->runManualInsert(); } $this->InsertedID = $this->PDO->lastInsertId(); if ($this->Object instanceof ObjectWithID) { $this->Object->setID($this->InsertedID); } }