Рекурсивный акроним словосочетания «PHP: Hypertext Preprocessor»
Добро пожаловать на форум PHP программистов!
За последние 24 часа нас посетили 17215 программистов и 1835 роботов. Сейчас ищут 1588 программистов ...
DB_common::freePrepared()
Вернуться к: DB
DB_common::freePrepared()
DB_common::freePrepared() – Releases resources associated with a prepared SQL statement
Synopsis
boolean freePrepared ( resource $stmt , boolean $free_resource = true )
Removes the memory occupied by the internal notations that keep track of prepared SQL statements. Does not delete the DB_result object itself.
Parameter
- resource $stmt
-
statement resource identifier returned from prepare()
- boolean $free_resource
-
should the PHP resource be freed too? Use false if you need to get data from the result set later.
Parameter available since Release 1.7.0.
Return value
boolean - Returns TRUE on success, FALSE on failure.
Note
This function can not be called statically.
Example
Using freePrepared()
<?php
// Once you have a valid DB object named $db...
$sth = $db->prepare('INSERT INTO numbers (number) VALUES (?)');
$db->execute($sth, 1);
$db->freePrepared($sth);
?>
See
Вернуться к: DB