in reply to Class::DBI and - possibly - complex data structures
it seems like Class::DBI forces you to name references without any ending '_id' if you want some nifty named methods in your classes?package Name; ... __PACKAGE__->set_sql(by_person => q/ SELECT n.name FROM name n, person_name pn WHERE (n.name_id = pn.firstname OR n.name_id = pn.lastname) AND pn.person = ? /); package Person; ... sub names { my $self = shift; Name->search_by_person($self); }
No, you can name things whatever you want. Look at the section on changing accessor names in the docs.
|
|---|