in reply to Re: OOP design related question.
in thread OOP design related question.

Already using sort of abstraction. It's a module that I'm working on - mentioned it on this node > 487823.

Anyway correct me if I'm wrong, but in case I wouldn't pass this object "around", every time I need DB access, new connection would be made?

I mean, CGI::Session would connect on itself, then once again my code to check the data and add user? Who knows how many connections would be made latter on when I add all sorts of things ... Obvisoly I'm using plain CGI, Apache::DBI (or whichever) is not available ...

Replies are listed 'Best First'.
Re^3: OOP design related question.
by Arunbear (Prior) on Sep 10, 2005 at 14:52 UTC
    No, Class::DBI is built on top of Ima::DBI which does database connection caching, so you wouldn't be re-connecting each time you use the Class::DBI objects.