in reply to Apache::Session::MySql using a_session

You can look at all the stuff that's already in an established session DB with something like this:

use Data::Dumper; $Data::Dumper::Terse = 1; $Data::Dumper::Indent = 1; use DBI; use Apache::Session::MySQL; my $dbh = DBI->connect('DBI:mysql:apache_session' . ':' . 'localhost' . ';mysql_read_default_file=/path/to/.my.cnf', undef, undef, ); ( my $sth = $dbh->prepare('SELECT id FROM sessions') )->execute; while ( my $id = $sth->fetchrow_array ) { my %session; tie %session, 'Apache::Session::MySQL', $id, { Handle => $dbh, LockHandle => $dbh }; print Dumper \%session; # you could edit or do whatever to %session here and get the # data back with the same $id later } $sth->finish; $dbh->disconnect;

For creating and manipulating the sessions, you should use the module itself, as CountZero suggested. It is in control of the "a_session" column's data (just a text field) and its serialization/retrieval, and you should almost certainly leave it that way.