[Catalyst] DBIC ResultSet - what columns in it?

Andreas Marienborg omega at palle.net
Wed Dec 19 06:12:18 GMT 2007


Wrong list, but $rs->result_source->columns might give you that?

http://cpansearch.perl.org/~ash/DBIx-Class-0.08008/lib/DBIx/Class/ResultSource.pm#columns


- andreas

On 19. des.. 2007, at 06.09, Silvio Almeida wrote:

> I was looking for a way to get column names from a ResultSet.
>
> If I have a table with columns id, to, from, subject which is mapped  
> into Email then if I do
>
> $c->model('Email')->{_source_handle}{schema}{source_registrations} 
> {Reuniao}{_ordered_columns}
>
> then I get [ qw/ id to from subject / ] indeed, but it would be nice  
> to have a simpler method to get there.
>
>
> Silvio
> _______________________________________________
> List: Catalyst at lists.scsys.co.uk
> Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
> Searchable archive: http://www.mail-archive.com/catalyst@lists.rawmode.org/
> Dev site: http://dev.catalyst.perl.org/




More information about the Catalyst mailing list