downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

db2_pconnect> <db2_num_rows
Last updated: Fri, 06 Nov 2009

view this page in

db2_pclose

(PECL ibm_db2 >= 1.8.0)

db2_pclose持続的データベース接続を閉じる

説明

bool db2_pclose ( resource $resource )

この関数は、 db2_pconnect() で作成した DB2 クライアント接続を閉じ、 対応するリソースをデータベースサーバに返します。

注意: この関数は、i5/OS で i5/OS システム管理リクエストに対する応答としてのみ使用可能です。

持続的 DB2 クライアント接続を db2_pconnect() で作成した場合は、 この関数で接続を閉じることができるでしょう。それ以降の接続のパフォーマンスのことを考えて、 この関数使うのは特別な場合だけにしておかなければなりません。 たとえば持続的接続が無反応になったり 当分の間は持続的接続が不要になったりした場合です。

パラメータ

connection

アクティブな DB2 クライアント接続。

返り値

成功した場合に TRUE を、失敗した場合に FALSE を返します。

例1 持続的接続の終了

次の例は、IBM DB2 i5/OS データベースへの接続を閉じるものです。

<?php
$conn 
db2_pconnect('''''');
$rc db2_pclose($conn);
if (
$rc) {
    echo 
"Connection was successfully closed.";
}
?>

上の例の出力は以下となります。

Connection was successfully closed.

参考



add a note add a note User Contributed Notes
db2_pclose
There are no user contributed notes for this page.

db2_pconnect> <db2_num_rows
Last updated: Fri, 06 Nov 2009
 
 
show source | credits | sitemap | contact | advertising | mirror sites