예제 #1
0
 protected function execute_internal()
 {
     APF::get_instance()->debug("MysqlAccessor execute internal:" . $this->sql);
     $className = $this->model_name;
     $this->connection = $this->get_connection($className::get_pdo_name($this));
     $stmt = $this->connection->prepare($this->sql);
     self::$last_sql = $this->sql;
     APF::get_instance()->debug("MysqlAccessor pdo_values:" . print_r($this->pdo_values, true));
     $stmt->execute($this->pdo_values);
     return $stmt;
 }
예제 #2
0
 /**
  *
  * @return PDOStatement
  */
 protected function execute_internal()
 {
     //var_dump($this->sql);
     //var_dump($this->pdo_values);die();
     APF::get_instance()->debug("MysqlAccessor execute internal:" . $this->sql);
     //die();
     $className = $this->model_name;
     //var_dump($className);die();
     $this->connection = $this->get_connection($className::get_pdo_name($this));
     //die();
     $stmt = $this->connection->prepare($this->sql);
     APF_DB_MysqlAccessor::$last_sql = $this->sql;
     $stmt->execute($this->pdo_values);
     return $stmt;
 }
예제 #3
0
 public static function data_access()
 {
     return APF_DB_MysqlAccessor::use_model(get_called_class());
 }