Skip to content

Commit 9d792d3

Browse files
authored
PDO: improve PDO::ATTR_STRINGIFY_FETCHES description (#4359)
1 parent 3c1bec9 commit 9d792d3

File tree

2 files changed

+8
-4
lines changed

2 files changed

+8
-4
lines changed

reference/pdo/constants.xml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -580,7 +580,9 @@ if ($db->getAttribute(PDO::ATTR_DRIVER_NAME) == 'mysql') {
580580
</term>
581581
<listitem>
582582
<simpara>
583-
Forces all values fetched to be treated as strings.
583+
Forces all fetched values (except &null;) to be treated as strings.
584+
&null; values remain unchanged unless <constant>PDO::ATTR_ORACLE_NULLS</constant>
585+
is set to <constant>PDO::NULL_TO_STRING</constant>.
584586
</simpara>
585587
</listitem>
586588
</varlistentry>

reference/pdo/pdo/setattribute.xml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -136,9 +136,11 @@
136136
<term><constant>PDO::ATTR_STRINGIFY_FETCHES</constant></term>
137137
<listitem>
138138
<para>
139-
Whether to convert numeric values to strings when fetching.
140-
Takes a value of type <type>bool</type>: &true; to enable and
141-
&false; to disable. <!-- By default, ??? TODO. -->
139+
Controls whether fetched values (except &null;) are converted to strings.
140+
Takes a value of type <type>bool</type>: &true; to enable and &false; to
141+
disable (default).
142+
&null; values remain unchanged unless <constant>PDO::ATTR_ORACLE_NULLS</constant>
143+
is set to <constant>PDO::NULL_TO_STRING</constant>.
142144
</para>
143145
</listitem>
144146
</varlistentry>

0 commit comments

Comments
 (0)