in reply to inheritance not working as expected

I ran into this just the other day. &DBI::connect returns a blessed reference to a DBI::db object, not a DBI oject:

$ perl -MDBI -e '$db = DBI->connect("DBI:mysql:database=test;user=x", +"x", "x"); print "\$db is a ", ref $db, "\n"' $db is a DBI::db

I just settle for a 'has-a' relationship (my object "has a" DBI thingy in it) and leave it at that, works fine. Oh, it might be a good idead to invoke the disconnect method in your DESTROY sub so you won't get those nasty little warnings when the object goes away.