php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #55025 PDO Base Class not supplied with archive
Submitted: 2011-06-10 15:09 UTC Modified: 2017-03-01 22:40 UTC
Votes:2
Avg. Score:2.0 ± 1.0
Reproduced:0 of 1 (0.0%)
From: wjaspers at nuaire dot com Assigned:
Status: Not a bug Package: PDO related
PHP Version: 5.3.6 OS: Win32
Private report: No CVE-ID: None
 [2011-06-10 15:09 UTC] wjaspers at nuaire dot com
Description:
------------
---
From manual page: http://www.php.net/class.pdo
---
When installing PHP5.3, there is no php_pdo.dll included with the PHP package. 
It's therefore impossible to use any of the PDO database drivers. 

Plus, using the php_pdo.dll from the latest PHP5.2 archive doesn't work because 
new constants aren't available to it.

Test script:
---------------
<?php
$pdo = new PDO( 
    'mysql:host=hostname;dbname=defaultDbName', 
    'username', 
    'password', 
    array(PDO::MYSQL_ATTR_INIT_COMMAND => "SET NAMES utf8") 
); 

Expected result:
----------------
$pdo should be a connection to a database

Actual result:
--------------
Fatal error: Class 'PDO' not found ...

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2012-02-24 17:35 UTC] kissifrot at gmail dot com
PDO base class is included in PHP 5.3, so you don't need a dll for it.
You need to activate the appropriate PDO extension DLL corresponding to your DB, php_pdo_mysql.dll in your case.
 [2017-03-01 22:40 UTC] adambaratz@php.net
-Status: Open +Status: Not a bug
 [2017-03-01 22:40 UTC] adambaratz@php.net
Shouldn't need to keep this open anymore. It's a user install issue with an no longer supported version of PHP.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Wed Jul 17 20:01:29 2024 UTC