Ejemplo n.º 1
0
 /**
  * @param \Doctrine\DBAL\Schema\Schema $schema
  * @return bool
  */
 private function executeSchemaChange($schema)
 {
     $this->conn->beginTransaction();
     foreach ($schema->toSql($this->conn->getDatabasePlatform()) as $sql) {
         $this->conn->query($sql);
     }
     $this->conn->commit();
     if ($this->conn->getDatabasePlatform() instanceof SqlitePlatform) {
         \OC_DB::reconnect();
     }
     return true;
 }