in reply to Class::DBI connect info from file?
And for each My::DBIpackage My::DBI::Config; use base qw/Class::DBI/; My::DBI::Config->set_db { ...
And you're done!package My::DBI; use base qw(My::DBI::Config);
See the docs:
Give it a database connection Class::DBI needs to know how to access the database. It do +es this through a DBI connection which you set up by calling the se +t_db() method. Music::DBI->set_db('Main', 'dbi:mysql:dbname', 'use +r', 'password'); By setting the connection up in your application base class + all the table classes that inherit from it will share the same conn +ection.
|
|---|