public function nextValue($name) { if (!$name) { return 0; } return $this->connection->selectOne("SELECT {$name}.NEXTVAL as id FROM DUAL")->id; }