PHP + mysql 遇到Uncaught exception 'PDOException' with message 'SQLSTATE[HY000]: General error

        一直开发着没有问题,今天早上一来,发现所有查询都没有问题,一有编辑和插入语句执行时就出问题:

<br />
<b>Warning</b>:  Uncaught exception 'PDOException' with message 'SQLSTATE[HY000]: General error: 1205 Lock wait timeout exceeded; try restarting transaction' in D:\xampp\htdocs\SinoStorage\library\Zend\Db\Statement\Pdo.php:228
Stack trace:
#0 D:\xampp\htdocs\SinoStorage\library\Zend\Db\Statement\Pdo.php(228): PDOStatement->execute(Array)
#1 D:\xampp\htdocs\SinoStorage\library\Zend\Db\Statement.php(303): Zend_Db_Statement_Pdo->_execute(Array)
#2 D:\xampp\htdocs\SinoStorage\library\Zend\Db\Adapter\Abstract.php(480): Zend_Db_Statement->execute(Array)
#3 D:\xampp\htdocs\SinoStorage\library\Zend\Db\Adapter\Pdo\Abstract.php(238): Zend_Db_Adapter_Abstract->query('UPDATE `AsnOrde...', Array)
#4 D:\xampp\htdocs\SinoStorage\library\Zend\Db\Adapter\Abstract.php(635): Zend_Db_Adapter_Pdo_Abstract->query('UPDATE `AsnOrde...', Array)
#5 D:\xampp\htdocs\SinoStorage\library\Zend\Db\Table\Abstract.php(1133): Zend_Db_Adapter_Abstract->update('AsnOrders', Array, 'ASNid = '67'')
#6 D:\xampp\htdocs\SinoStorage\application\modules\product\models\A in <b>D:\xampp\htdocs\SinoStorage\library\Zend\Db\Statement\Pdo.php</b> on line <b>228</b><br />
<br />
<b>Fatal error</b>:  Maximum execution time of 30 seconds exceeded in <b>D:\xampp\htdocs\SinoStorage\library\Zend\Db\Statement\Pdo.php</b> on line <b>228</b><br />
       找了很久,终于发现,我的站点文件夹:里面包括,PHP + mysql + apache,该文件夹属性显示:只读,我终于瞬间醒悟了,看到这里,大家也应该知道什么问题了。

       对,就是由于文件夹是只读,所有数据插入,修改都无法写入。

      解决办法就不用我说了吧?修改文件夹属性之类的,应该都会了吧!

      最后:记得重启apache和mysql数据库哦!

你可能感兴趣的:(PHP + mysql 遇到Uncaught exception 'PDOException' with message 'SQLSTATE[HY000]: General error)