Tim Bunce wrote:
>
> I'd expect it to be hooked into the real DBI.pm something like this:
>
> eval {
> bootstrap DBI;
> };
> if ($@) {
> my $error = $@;
> die $error unless $error =~ /.../ # DBI.xs not available
warn "SWITCHING TO DBI::PurePerl! YOU REALLY SHOULD INSTALL
THE REAL THING!";
> die $error unless eval { require DBI::PurePerl; }
> }
> DBI::PurePerl would start with 'package DBI;' and define all
> the functions and methods that DBI.xs currently does.
Ok, I am now using that setup and I have it more or less working for the
basic methods such that I was able to build and query tables via
DBD::XBase, DBD::CSV, and DBD::ADO with no loadable object for DBI and
nothing DBD specific in the DBI::PurePerl and all of it coming through
the standard DBI.pm (modified only with the bootstrap code above). I
can't say as I completely understand the inner and outer ties or know
the best way to make a general method dispatcher so I would appreciate
any help anyone cares to give.
--
Jeff