What if you already have the database connection open in your code? Do you want your objects to open a new connection per object?
But creating a $self->{dbh} is probably a good idea. I would do something like:
my $person = People->new(dbh => $dbh, %other_data);
In reply to Re: Re: Object Oriented Pattern help
by DrZaius
in thread Object Oriented Pattern help
by thefid
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |