cubrid_free_result

(PECL CUBRID >= 8.3.0)

cubrid_free_result — 결과 데이터가 차지하는 메모리 해제


설명

cubrid_free_result(resource $req_identifier): bool

이 함수는 결과 데이터가 차지하는 메모리를 해제합니다. 성공하면 true를, 실패하면 false를 반환합니다. 지금은 클라이언트 fetch 버퍼만 해제할 수 있으며, 모든 메모리를 해제하려면 cubrid_close_request() 함수를 사용한다.


매개변수

req_identifier
요청 식별자입니다.

반환 값

성공하면 true를, 실패하면 false를 반환합니다.


Examples

예제 #1 cubrid_free_result() 예제

                  
<?php
$conn = cubrid_connect("localhost", 33000, "demodb");

$req = cubrid_execute($conn, "SELECT * FROM history WHERE host_year=2004 ORDER BY event_code");
$row = cubrid_fetch_assoc($req);
var_dump($row);

cubrid_free_result($req);
cubrid_close_request($req);
cubrid_disconnect($conn);
?>
                  
                

위의 예는 다음을 출력합니다.

array(5) {
  ["event_code"]=>
  string(5) "20005"
  ["athlete"]=>
  string(12) "Hayes Joanna"
  ["host_year"]=>
  string(4) "2004"
  ["score"]=>
  string(5) "12.37"
  ["unit"]=>
  string(4) "time"
}