Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re^3: Inheriting from DBI

by runrig (Abbot)
on Mar 03, 2011 at 15:52 UTC ( [id://891248]=note: print w/replies, xml ) Need Help??


in reply to Re^2: Inheriting from DBI
in thread Inheriting from DBI

Your class doesn't need to inherit from DBI, it just needs to return a database handle. I've written lots of wrappers that connect to some default database in some default way that goes something like:
package MyDBI; use DBI; sub connect { ...get args my $dbh; ...do stuff $dbh = DBI->connect(...); ...do more stuff return $dbh; }

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://891248]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others musing on the Monastery: (3)
As of 2024-04-24 04:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found