[Dbix-class] Re: Get table name from ResultSet class?

Lyle Kopnicky lwk at rentrakmail.com
Thu Sep 22 21:04:04 GMT 2011


I just found an easier solution. Instead of:

__PACKAGE__->table_class('My::Schema::ResultSource::MyTable');

I override the table_class accessor:

sub table_class { 'My::Schema::ResultSource::MyTable' }

That way when sub table is called, the table_class is already defined.

- Lyle
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.scsys.co.uk/pipermail/dbix-class/attachments/20110922/715=
83019/attachment.htm


More information about the DBIx-Class mailing list