#36085 [Opn->Csd]: Provide example for mysqli_stmt_send_long_data

From: Date: Mon, 30 Jan 2006 16:15:17 +0000
Subject: #36085 [Opn->Csd]: Provide example for mysqli_stmt_send_long_data
References: 1  Groups: php.doc 
Request: Send a blank email to phpdoc+get-969371777@lists.php.net to get a copy of this message
ID: 36085 Updated by: vrana@php.net Reported By: ate2 at cornell dot edu -Status: Open +Status: Closed Bug Type: Documentation problem PHP Version: Irrelevant New Comment: This bug has been fixed in the documentation's XML sources. Since the online and downloadable versions of the documentation need some time to get updated, we would like to ask you to be a bit patient. Thank you for the report, and for helping us make our documentation better. <?php $stmt = $mysqli->prepare("INSERT INTO messages (message) VALUES (?)"); $stmt->bind_param("b", $null); $fp = fopen("messages.txt", "r"); while (!feof($fp)) { $stmt->send_long_data(0, fread($fp, 8192)); } fclose($fp); $stmt->execute(); ?> Previous Comments: ------------------------------------------------------------------------ [2006-01-19 14:17:51] ate2 at cornell dot edu Description: ------------ It would be much easier to use this method with an example of how it is supposed to be used. None of the following is explained in present documentation: How to break data into packets. Whether to use the mysqli_stmt_execute method before/after this method. I assume we're not supposed to bind a variable to the placeholder for which we are using this method. What if that parameter is set initially? ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=36085&edit=1

« previous php.doc (#969371777) next »