mirror of
https://github.com/sigmasternchen/php-doc-en
synced 2025-03-16 08:58:56 +00:00
Adding note about usage of PDO::ATTR_PERSISTENT in the constructor vs. PDO->setAttribute
git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@245222 c90b9560-bf6c-de11-be94-00142212c4b1
This commit is contained in:
parent
06fb5b2615
commit
0d571af650
1 changed files with 10 additions and 1 deletions
|
@ -1,5 +1,5 @@
|
|||
<?xml version='1.0' encoding='iso-8859-1'?>
|
||||
<!-- $Revision: 1.58 $ -->
|
||||
<!-- $Revision: 1.59 $ -->
|
||||
<!-- Purpose: database.abstract -->
|
||||
<!-- Membership: pecl, bundled -->
|
||||
|
||||
|
@ -198,6 +198,15 @@ $dbh = new PDO('mysql:host=localhost;dbname=test', $user, $pass, array(
|
|||
</programlisting>
|
||||
</example>
|
||||
</para>
|
||||
<note>
|
||||
<para>
|
||||
If you wish to use persistent connections, you must set
|
||||
<constant>PDO::ATTR_PERSISTENT</constant> in the array of driver options
|
||||
passed to the PDO constructor. If setting this attribute with
|
||||
<xref linkend="function.PDO-setAttribute" /> after instantiation of the
|
||||
object, the driver will not use persistent connections.
|
||||
</para>
|
||||
</note>
|
||||
<note>
|
||||
<para>
|
||||
If you're using the PDO ODBC driver and your ODBC libraries support ODBC
|
||||
|
|
Loading…
Reference in a new issue