[Dbix-class] Get the column names from a resultset

RAPPAZ Francois francois.rappaz at unifr.ch
Tue Jul 1 12:05:36 GMT 2014


I understand that I can retrieve a limited list of columns from a table using

$rs = $self->{schema}->resultset('User')->search_rs(undef, {columns => [qw / id_user nom prenom / ], order_by => 'nom',});

Now, is there a way to retrieve the columns names from a result set, when such a object is received as an argument ?

Is there a way to have

@colnames = $resultset->get_column_names;  

?? 

Thanks

François Rappaz

Centre de documentation de la Faculté des Sciences Université de Fribourg DokPe - Dokumentationszentrum der Naturwissenschaftlichen Fakultät Universität Freiburg Pérolles CH-1700 Fribourg Switzerland http://www.unifr.ch/dokpe/
Tel.: 41 (0)26 300 92 60
Fax.: 41 (0)26 300 97 30





More information about the DBIx-Class mailing list