On Tue, Jul 07, 2009 at 06:02:02PM +1200, Dan Horne wrote:
> Hi all
>
> This morning I generated my schema using DBIX::Schema::Loader and spent
> the best part of a day trying to debug the following message;
>
> DBIx::Class::Row::get_column(): Can't fetch data as class method at
> (eval 74) line 6
>
> After much faffing around, I managed to zero in on the error. i had the
> following definition in a class:
>
> "source_name",
> {
> data_type => "VARCHAR2",
> default_value => undef,
> is_nullable => 0,
> size => 50,
> },
>
> It seems there must be some collision between the column name and
> something in DBIC. So, how can I progress if I can't change the column
> name in the underlying table?
>
You diagnosed everything correctly, this is an unfortunate clash. Look at
the POD for DBIC::ResultSource::add_columns(), especially the 'accessor'
attribute.
Cheers
_______________________________________________
List: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbix-class
IRC: irc.perl.org#dbix-class
SVN: http://dev.catalyst.perl.org/repos/bast/DBIx-Class/
Searchable Archive: http://www.grokbase.com/group/[email protected]