reference/mysqli/mysqli_stmt/attr-set.xml
61374bbe228e8e9c55a24aba59a1e2bb2a871148
...
...
@@ -1,7 +1,6 @@
1
1
<?xml version="1.0" encoding="utf-8"?>
2
2
<!-- $Revision$ -->
3
-

4
-
<refentry xmlns="http://docbook.org/ns/docbook" xml:id="mysqli-stmt.attr-set" xmlns:xlink="http://www.w3.org/1999/xlink">
3
+
<refentry xml:id="mysqli-stmt.attr-set" xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink">
5
4
<refnamediv>
6
5
<refname>mysqli_stmt::attr_set</refname>
7
6
<refname>mysqli_stmt_attr_set</refname>
...
...
@@ -11,17 +10,17 @@
11
10
<refsect1 role="description">
12
11
&reftitle.description;
13
12
<para>&style.oop;</para>
14
-
<methodsynopsis role="oop">
15
-
<type>bool</type><methodname>mysqli_stmt::attr_set</methodname>
16
-
<methodparam><type>int</type><parameter>attr</parameter></methodparam>
17
-
<methodparam><type>int</type><parameter>mode</parameter></methodparam>
13
+
<methodsynopsis role="mysqli_stmt">
14
+
<modifier>public</modifier> <type>bool</type><methodname>mysqli_stmt::attr_set</methodname>
15
+
<methodparam><type>int</type><parameter>attribute</parameter></methodparam>
16
+
<methodparam><type>int</type><parameter>value</parameter></methodparam>
18
17
</methodsynopsis>
19
18
<para>&style.procedural;</para>
20
19
<methodsynopsis>
21
20
<type>bool</type><methodname>mysqli_stmt_attr_set</methodname>
22
-
<methodparam><type>mysqli_stmt</type><parameter>stmt</parameter></methodparam>
23
-
<methodparam><type>int</type><parameter>attr</parameter></methodparam>
24
-
<methodparam><type>int</type><parameter>mode</parameter></methodparam>
21
+
<methodparam><type>mysqli_stmt</type><parameter>statement</parameter></methodparam>
22
+
<methodparam><type>int</type><parameter>attribute</parameter></methodparam>
23
+
<methodparam><type>int</type><parameter>value</parameter></methodparam>
25
24
</methodsynopsis>
26
25
<para>
27
26
Used to modify the behavior of a prepared statement. This function may be
...
...
@@ -33,11 +32,11 @@
33
32
&reftitle.parameters;
34
33
<para>
35
34
<variablelist>&mysqli.stmt.description;<varlistentry>
36
-
<term><parameter>attr</parameter></term>
35
+
<term><parameter>attribute</parameter></term>
37
36
<listitem>
38
37
<para>
39
38
The attribute that you want to set. It can have one of the following values:
40
-
<table>
39
+
<table xml:id="mysqli-stmt.attr-set.parameters">
41
40
<title>Attribute values</title>
42
41
<tgroup cols="2">
43
42
<thead>
...
...
@@ -51,22 +50,22 @@
51
50
<entry>MYSQLI_STMT_ATTR_UPDATE_MAX_LENGTH</entry>
52
51
<entry>
53
52
Setting to &true; causes <function>mysqli_stmt_store_result</function> to
54
-
update the metadata <literal>MYSQL_FIELD->max_length</literal> value.
53
+
update the metadata <literal>MYSQL_FIELD-&gt;max_length</literal> value.
55
54
</entry>
56
55
</row>
57
56
<row>
58
57
<entry>MYSQLI_STMT_ATTR_CURSOR_TYPE</entry>
59
58
<entry>
60
59
Type of cursor to open for statement when <function>mysqli_stmt_execute</function>
61
-
is invoked. <parameter>mode</parameter> can be <literal>MYSQLI_CURSOR_TYPE_NO_CURSOR</literal>
62
-
(the default) or <literal>MYSQLI_CURSOR_TYPE_READ_ONLY</literal>.
60
+
is invoked. <parameter>value</parameter> can be <constant>MYSQLI_CURSOR_TYPE_NO_CURSOR</constant>
61
+
(the default) or <constant>MYSQLI_CURSOR_TYPE_READ_ONLY</constant>.
63
62
</entry>
64
63
</row>
65
64
<row>
66
65
<entry>MYSQLI_STMT_ATTR_PREFETCH_ROWS</entry>
67
66
<entry>
68
67
Number of rows to fetch from server at a time when using a cursor.
69
-
<parameter>mode</parameter> can be in the range from 1 to the maximum
68
+
<parameter>value</parameter> can be in the range from 1 to the maximum
70
69
value of unsigned long. The default is 1.
71
70
</entry>
72
71
</row>
...
...
@@ -75,8 +74,8 @@
75
74
</table>
76
75
</para>
77
76
<para>
78
-
If you use the <literal>MYSQLI_STMT_ATTR_CURSOR_TYPE</literal> option with
79
-
<literal>MYSQLI_CURSOR_TYPE_READ_ONLY</literal>, a cursor is opened for the
77
+
If you use the <constant>MYSQLI_STMT_ATTR_CURSOR_TYPE</constant> option with
78
+
<constant>MYSQLI_CURSOR_TYPE_READ_ONLY</constant>, a cursor is opened for the
80
79
statement when you invoke <function>mysqli_stmt_execute</function>. If there
81
80
is already an open cursor from a previous <function>mysqli_stmt_execute</function> call,
82
81
it closes the cursor before opening a new one. <function>mysqli_stmt_reset</function>
...
...
@@ -90,7 +89,7 @@
90
89
</listitem>
91
90
</varlistentry>
92
91
<varlistentry>
93
-
<term><parameter>mode</parameter></term>
92
+
<term><parameter>value</parameter></term>
94
93
<listitem>
95
94
<para>The value to assign to the attribute.</para>
96
95
</listitem>
...
...
@@ -99,6 +98,18 @@
99
98
</para>
100
99
</refsect1>
101
100

101
+
<refsect1 role="returnvalues">
102
+
&reftitle.returnvalues;
103
+
<para>
104
+
&return.success;
105
+
</para>
106
+
</refsect1>
107
+

108
+
<refsect1 role="errors">
109
+
&reftitle.errors;
110
+
&mysqli.conditionalexception;
111
+
</refsect1>
112
+

102
113
<refsect1 role="seealso">
103
114
&reftitle.seealso;
104
115
<para>
...
...
@@ -109,7 +120,6 @@
109
120
</refsect1>
110
121

111
122
</refentry>
112
-

113
123
<!-- Keep this comment at the end of the file
114
124
Local variables:
115
125
mode: sgml
116
126