CGI-Session - Re: reuse dbh handle with mysql

Posted on Mon Jun 30 07:40:58 2008 by nekatreven in response to 8197 (See the whole thread of 2)
Re: reuse dbh handle with mysql
The following is the log from mysql that was written while I was troubleshooting. Connect and query set 8 occurred when I thought maybe the handle was going out of scope. I added a useless query below the section for the session by looking for the user 'cheesypoofs' after the attempt at the new session. The results were no different.

9 and 10 were when I thought I might need to $dbh->disconnect() before the session->new();. As you can see it just made a new connection, no other changes.

What is odd is that, as you can see, the session id is not changing. I have a debug print statement for the id in my code, and that is not the ID that is being generated. However there are no session rows in MySql and I've cleared the cookies in my browser. (server and client are same machine at the moment)
8 Connect *******@localhost on test 8 Query set autocommit=1 8 Query SELECT username FROM users WHERE username = 'bob' 8 Query SELECT password FROM users WHERE username = 'bob' 8 Query SELECT a_session FROM sessions WHERE id='c11b3b1e9fdb1f0305734017fb25ee88' 8 Query SELECT password FROM users WHERE username = 'cheesypoofs' 8 Quit 9 Connect *********@localhost on test 9 Query set autocommit=1 9 Query SELECT username FROM users WHERE username = 'bob' 9 Query SELECT password FROM users WHERE username = 'bob' 9 Quit 10 Connect root@localhost on test 10 Query SELECT a_session FROM sessions WHERE id='c11b3b1e9fdb1f0305734017fb25ee88'
Write a response