Exemple #1
0
 /**
  * {@inheritDoc}
  */
 protected function getDumpPairsString()
 {
     return $this->replaceQueryOrdering(parent::getDumpPairsString());
 }
Exemple #2
0
 /**
  * {@inheritDoc}
  *
  * @throws \Exception When database cannot be connected to
  */
 public function connect()
 {
     parent::connect();
     // For debugging and sanity, make PDO report any problems, not fail silently
     $this->pdoObject->setAttribute(\PDO::ATTR_ERRMODE, \PDO::ERRMODE_EXCEPTION);
     try {
         $this->pdoObject->exec('USE ' . $this->dbName);
     } catch (\PDOException $e) {
         throw new \Exception('Failed to access database named ' . $this->dbName . ' // ' . $e->getMessage());
     }
     if (!$this->isInit()) {
         $this->init();
         // Init the database if required
     }
 }