[Dbix-class] Concats and Group Concats

Brandi b.cantarel at gmail.com
Mon Jan 19 10:36:28 GMT 2009


I am trying to do a group concat select statement in DBIx class, is
this possible??

I have the statement:

select fam_acc, subf, group_concat(concat(description, " (EC
",ec_num,")") separator '; ') from family inner join fam_func
using(fam_id) inner join function using(function_id) where fam_acc =
'GH2' and subf is NULL group by fam_id order by ec_num;

And I have the search statement:

$fam_desc_search = $family_rs->search({fam_acc=>$fam,subf=>$sfam},
					      {join=>{'fam_func'=>'function'},
					       order_by=>[qw/'ec_num'/],
					       group_by=>[qw/'fam_id'/]
					      }
					     );

How do I get the group_concat/concat in the results?  +select?

Brandi



More information about the DBIx-Class mailing list