php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #33916 Unknown MySQL server host '.'
Submitted: 2005-07-29 12:07 UTC Modified: 2005-07-29 16:36 UTC
From: deadman_great at mail dot ru Assigned: wez (profile)
Status: Closed Package: PDO related
PHP Version: 5.0.4 OS: RH fedora, core 2
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 this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: deadman_great at mail dot ru
New email:
PHP Version: OS:

 

 [2005-07-29 12:07 UTC] deadman_great at mail dot ru
Description:
------------
PDO Couldn't connect to MySQL.

Reproduce code:
---------------
<?

$pdo = new PDO('mysql:host=localhost;dbname=test','root','xxxxxxxxxx');

?>

Expected result:
----------------
PDO connection.

Actual result:
--------------
Fatal error: Uncaught exception 'PDOException' with message 'SQLSTATE[HY000] [2005] Unknown MySQL server host '.' (4)' in /home/tech/pages/mywatch/pdo.php:3 Stack trace: #0 /home/tech/pages/mywatch/pdo.php(3): PDO->__construct('mysql:host=loca...', 'root', 'xxxxxxxxxx...') #1 {main} thrown in /home/tech/pages/mywatch/pdo.php on line 3

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-07-29 12:10 UTC] tony2001@php.net
Please try using this CVS snapshot:

  http://snaps.php.net/php5-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php5-win32-latest.zip


 [2005-07-29 15:33 UTC] wez@php.net
Please tell us which PDO/PDO_MYSQL versions you have in your PHP 5.0.4 install.
 [2005-07-29 16:20 UTC] deadman_great at mail dot ru
PDO v0.3 & PDO_MySQL v0.2.

PS: I think that PDO is bundled in php 5.1.x, but I can't install it, because zend optimizer won't work on it.
 [2005-07-29 16:36 UTC] wez@php.net
Upgrade them to 0.9; this was fixed long ago.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Apr 25 21:01:36 2024 UTC