Returns the primary key for the passed class type.
If the type does not yet exist in the database, it will be created.
string $classType:
integer
private function createOrRetrieveClassId($classType) {
if (false !== ($id = $this->connection
->executeQuery($this
->getSelectClassIdSql($classType))
->fetchColumn())) {
return $id;
}
$this->connection
->executeQuery($this
->getInsertClassSql($classType));
return $this->connection
->executeQuery($this
->getSelectClassIdSql($classType))
->fetchColumn();
}