Active
Project:
Drupal API + Extensions
Version:
6.x-1.x-dev
Component:
Code
Priority:
Critical
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
4 Apr 2012 at 14:19 UTC
Updated:
7 Jun 2012 at 11:46 UTC
While clicking on Drupal 7.12 Configuration tab
Uncaught exception thrown in session handler.
PDOException: SQLSTATE[HY000]: General error: 2014 Cannot execute queries while other unbuffered queries are active. Consider using PDOStatement::fetchAll(). Alternatively, if your code is only ever going to run against mysql, you may enable query buffering by setting the PDO::MYSQL_ATTR_USE_BUFFERED_QUERY attribute. in _drupal_session_write() (line 207 of /opt/lampp/htdocs/transform/includes/session.inc).
Comments
Comment #1
premgangwar commentedIt shows you did not installed php module for msyql.
Use this command to install php module on ubuntu
sudo apt-get install php5-mysql. This works for me.
Comment #2
liberatrHi ilechcod,
We are having a similar error - in this case we are using the "tokenauth" module, and there are some connections to a Postgres DB in the background, in addition to MySQL. I saw a page that refers to the error premgangwar is talking about - I don't think that General error 2014 would show up if you did not have the mysql extension installed - we have it on our machine.
I went to go see how I could turn on this MYSQL variable and it turns out Drupal's database layer turns it on by default.
http://api.drupal.org/api/drupal/includes%21database%21mysql%21database....
Line 22 - they set it to TRUE.
Setting it to false causes errors on every page instead of just the one we had a problem with.
Comment #3
ilechcod commented@liberatr,
I think you are right. I do have the mysql extension installed (actually I am using lampp - so the possibility of not having that installed is near zero -since the whole package comes together).
So what then is the solution to this error? I'm scared it might show up on my production site sometime soon.
Comment #4
AFFLemos commentedHi,
I've just upgraded around 10 modules and now this error appears.
As far as i can see, everything is like the code in the link
What can i do?
Cheers,
Comment #5
ilechcod commented@AFFLemos,
Could you please post your Drupal, apache, php, and mysql configurations?
Comment #6
AFFLemos commentedHi ilechcod,
it was a server problem because i asked the hosting company and they fixed the problem.
Thanks