$sth->execute;
my $table_def = $sth->fetchrow_arrayref->[1] || '';
- my (@reldata) = ($table_def =~ /CONSTRAINT `.*` FOREIGN KEY \(`(.*)`\) REFERENCES `(.*)` \(`(.*)`\)/g);
+ my (@reldata) = ($table_def =~ /CONSTRAINT `.*` FOREIGN KEY \(`(.*)`\) REFERENCES `(.*)` \(`(.*)`\)/ig);
while (scalar @reldata > 0) {
my $cols = shift @reldata;
$cond->{$f_cols[$i]} = $cols[$i];
}
- eval { $class->_loader_make_relations( $table, $f_table, $cond) };
+ eval { $class->_loader_make_cond_rel( $table, $f_table, $cond) };
warn qq/\# belongs_to_many failed "$@"\n\n/ if $@ && $class->_loader_debug;
}