function cubrid_mysql_num_fields($resultSet)
{
    return cubrid_num_cols($resultSet);
}
示例#2
0
 /**
  * @group php-822
  */
 public function testCubridNumCols2()
 {
     if (OUTPUT_FUNCTION_NAME == true) {
         echo "\r\nRunning: " . __FUNCTION__ . " = ";
     }
     $this->sql = "create table test1 (id int, name varchar(30), age int)";
     cubrid_execute($this->con, $this->sql);
     $this->sql = "insert into test1 values(1, 'test', 10)";
     $this->req = cubrid_execute($this->con, $this->sql);
     $this->sql = "insert into test1 values(2, 'cj', 20)";
     $this->req = cubrid_execute($this->con, $this->sql);
     $this->sql = "select * from test1";
     $this->req = cubrid_execute($this->con, $this->sql);
     // use wrong parameter
     try {
         cubrid_num_cols($this->con);
     } catch (Exception $e) {
         //echo cubrid_error_code();
         $this->assertTrue(TRUE);
         //echo $e->getMessage();
     }
 }