[Dbix-class] question about change in prefetch behavior

Greg Hill gnhill at liquidweb.com
Wed Jul 25 20:27:08 GMT 2012


On 07/25/2012 01:20 PM, Greg Hill wrote:
> my $rs = $table->search(
>         $search,
>         {
>             prefetch => 'product_region_prices', # this is a has_many
>             cache    => 1,
>         }
>     );
>     # passes $rs to a function that iterates through the whole thing
>     $rs->next;

That should be (I was snipping out the irrelevant bits and changed this 
on accident):

$rs->reset;

> while (my $product = $rs->next) {
>     }
>
> And I get this error:
>
> "Unable to calculate a definitive collapse column set for 
> product_data: fetch more unique non-nullable columns"
>

Greg



More information about the DBIx-Class mailing list