Apache::Mysql - Initiate a persistent database connection to Mysql
use Apache::Mysql; $dbh = Apache::Mysql->connect(...);
This module supplies a persistent database connection to Mysql. You will need to have mysqlperl installed on your system. You should really use Apache::DBI instead of this module (this module was written when DBI::Mysql had problems, which have since been corrected).
This is the first version of the first module I have ever written, so expect errors! Any feedback or suggestions are gratefully received.
All you really need is to replace Mysql with Apache::Mysql. When connecting to a database the module looks if a database handle from a previous connect request is already stored. If not, a new connection is established and the handle is stored for later re-use. The destroy method has been intentionally left empty.
Apache(3), Mysql(3)
MySQL and mysqlperl by Michael (Monty) Widenius <month@tcx.se> mod_perl by Doug MacEachern <dougm@osf.org> Apache::Mysql by Neil Jensen <njensen@habaneros.com>
To install Apache::Mysql, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Apache::Mysql
CPAN shell
perl -MCPAN -e shell install Apache::Mysql
For more information on module installation, please visit the detailed CPAN module installation guide.