|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2010-04-23 19:03 UTC] felipe@php.net
-Status: Open
+Status: Assigned
-Assigned To:
+Assigned To: mysql
[2010-04-23 19:09 UTC] felipe@php.net
-Status: Assigned
+Status: Feedback
[2010-04-23 19:09 UTC] felipe@php.net
[2011-01-04 14:04 UTC] uw@php.net
-Status: Feedback
+Status: Wont fix
[2011-01-04 14:04 UTC] uw@php.net
[2011-01-04 20:39 UTC] foo-script at o2 dot pl
|
|||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Dec 05 22:00:02 2025 UTC |
Description: ------------ A "test script" produced following exception: exception 'PDOException' with message 'SQLSTATE[HY000]: General error' in L:\Program Files\Apache Software Foundation\Apache2.2\htdocs\readme.php:44 Stack trace: #0 L:\Program Files\Apache Software Foundation\Apache2.2\htdocs\readme.php(44): unknown() #1 {main} However, database have been successfuly created. Test script: --------------- try{ $pdo=new PDO('mysql:host='.$dbHost.';'.'dbname=mysql;'.'port='.$port, 'root', $dbKey, array(PDO::MYSQL_ATTR_INIT_COMMAND => 'SET NAMES \'UTF8\'')); $pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION); $result=$pdo->query('CREATE DATABASE test;'); } Expected result: ---------------- In my opinion exception should not be thrown, cause effect is good.