Files
php-doc-ru/reference/mysqlnd_uh/mysqlnduhpreparedstatement/execute.xml
sergey 9eee6645bd new: mysql_xdevapi
git-svn-id: https://svn.php.net/repository/phpdoc/ru/trunk@347710 c90b9560-bf6c-de11-be94-00142212c4b1
2019-07-06 06:36:17 +00:00

129 lines
3.4 KiB
XML
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision$ -->
<!-- EN-Revision: ed710737ea7ce93f1289809cf89170c6d48b72a6 Maintainer: sergey Status: ready -->
<!-- Reviewed: no -->
<refentry xml:id="mysqlnduhpreparedstatement.execute" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
<refnamediv>
<refname>MysqlndUhPreparedStatement::execute</refname>
<refpurpose>Выполняет подготовленный запрос</refpurpose>
</refnamediv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<modifier>public</modifier> <type>bool</type><methodname>MysqlndUhPreparedStatement::execute</methodname>
<methodparam><type>mysqlnd_prepared_statement</type><parameter>statement</parameter></methodparam>
</methodsynopsis>
<para>
Выполняет подготовленный запрос.
</para>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
<variablelist>
<varlistentry>
<term><parameter>statement</parameter></term>
<listitem>
<para>
Подготовленный Mysqlnd оператор дескриптора. Не изменяйте его!
Ресурс типа <literal>Mysqlnd Prepared Statement (internal only - you must not modify it!)</literal>.
</para>
</listitem>
</varlistentry>
</variablelist>
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
Возвращает &true; в случае успешного выполнения.
   В противном случае возвращает &false;
</para>
</refsect1>
<refsect1 role="examples">
&reftitle.examples;
<para>
<example>
<title>Пример использования <function>MysqlndUhPreparedStatement::execute</function></title>
<programlisting role="php">
<![CDATA[
<?php
class stmt_proxy extends MysqlndUhPreparedStatement {
public function execute($res) {
printf("%s(", __METHOD__);
var_dump($res);
printf(")\n");
$ret = parent::execute($res);
printf("%s returns %s\n", __METHOD__, var_export($ret, true));
var_dump($ret);
return $ret;
}
}
mysqlnd_uh_set_statement_proxy(new stmt_proxy());
$mysqli = new mysqli("localhost", "root", "", "test");
$stmt = $mysqli->prepare("SELECT 'Labskaus' AS _msg FROM DUAL");
$stmt->execute();
$msg = NULL;
$stmt->bind_result($msg);
$stmt->fetch();
var_dump($msg);
?>
]]>
</programlisting>
&example.outputs;
<screen>
<![CDATA[
stmt_proxy::execute(resource(256) of type (Mysqlnd Prepared Statement (internal only - you must not modify it!))
)
stmt_proxy::execute returns true
bool(true)
string(8) "Labskaus"
]]>
</screen>
</example>
</para>
</refsect1>
<refsect1 role="seealso">
&reftitle.seealso;
<para>
<simplelist>
<member>
<function>mysqlnd_uh_set_statement_proxy</function>
</member>
<member>
<function>mysqli_stmt_execute</function>
</member>
</simplelist>
</para>
</refsect1>
</refentry>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
indent-tabs-mode:nil
sgml-parent-document:nil
sgml-default-dtd-file:"~/.phpdoc/manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->