Esempio n. 1
0
 public function execute($sql)
 {
     foreach ($this->connection as $connection) {
     }
     if (!$connection) {
         return [['ERRO' => translate('app', 'database.erro1', [1 => self::getError()])]];
     }
     try {
         return $connection->exec($sql);
     } catch (PDOException $e) {
         self::$error[] = $e->getMessage();
         Debug::getInstance('exceptions')->addException($e);
     }
 }
Esempio n. 2
0
 public function execute($sql)
 {
     foreach ($this->connection as $connection) {
     }
     try {
         return $connection->exec($sql);
     } catch (PDOException $e) {
         self::$error[] = $e->getMessage();
         Debug::getInstance('exceptions')->addException($e);
     }
 }