Subject: | Can't use define_named_connections() && new() |
When trying to use define_named_connections(), like so:
DBIx::SQLEngine -> define_named_connections(test => [@_]);
DBIx::SQLEngine -> new('test');
the call to new() ends up at line 46 of DBIx::AnyDBD with this error:
Can't coerce array into hash at c:/Perl/site/lib/DBIx/AnyDBD.pm line 46.
Line 46 is:
my $driver = ucfirst($self->{dbh}->{Driver}->{Name});
If I dump $self->{dbh} just before that line, it shows $self->{dbh}
is the array ref passed into define_named_connections().
This is the (symptom of) the problem.
Note: I put some prints elsewhere in AnyDBD.pm, and this shows
rebless() is not being called from either new() nor connect().