php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #49736 PDO::prepare return value description incomplete ?
Submitted: 2009-10-01 15:05 UTC Modified: 2009-11-13 21:44 UTC
From: michael202 at gmx dot de Assigned:
Status: Closed Package: Documentation problem
PHP Version: 5.3.0 OS: linux
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: michael202 at gmx dot de
New email:
PHP Version: OS:

 

 [2009-10-01 15:05 UTC] michael202 at gmx dot de
Description:
------------
PDO::prepare returns false OR an exception

because the return value depends on the error mode ?!?

default behaviour is: 
return false

can be changed with
PDO->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_SILENT); 
or
PDO->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); 

Is it configurable in the php.ini ?

Can you please specify the documentation ?

Reproduce code:
---------------
---
From manual page: pdo.prepare#Return Values
---


Expected result:
----------------
not relevant

Actual result:
--------------
not relevant

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-11-13 21:44 UTC] svn@php.net
Automatic comment from SVN on behalf of vrana
Revision: http://svn.php.net/viewvc/?view=revision&revision=290706
Log: Can return false (bug #49736)
 [2009-11-13 21:44 UTC] vrana@php.net
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 Copyright © 2001-2026 The PHP Group
All rights reserved.
Last updated: Thu Jun 18 08:00:02 2026 UTC