Good afternoon,

On 21/01/13 at 5:39 PM -0300, Paula <> wrote:

>2013/1/21 Dagfinn Ilmari Mannsåker <>
>> ->search($where, { %{$attr}, prefetch => 'mc', join => 'mt' });
>I have just tried that, and again I get:
>[error] DBIx::Class::Row::get_column(): No such column 'h1'
>It seems the order is important, the last argument (prefetch or join) is
>the only one that is executed...

Correct, since standard perl behaviour says there is only one key in a hash.

Assuming $attr->{join} is currently a string (if already arrayref then just 
push onto it):

  $attr->{join} = [$attr->{join}, 'mt'];
  $attr->{prefetch} = [$attr->{prefetch}, 'mc'];
  search($where, $attr});


   Ꮚ Charlie Garrison ♊ <>
O< ascii ribbon campaign - stop html mail -

Searchable Archive:

Reply via email to