| DBIx-Class-Schema-Loader documentation | Contained in the DBIx-Class-Schema-Loader distribution. |
DBIx::Class::Schema::Loader::DBI::ODBC - DBD::ODBC proxy
Reblesses into an ::ODBC:: class when connecting via DBD::ODBC.
Code stolen from the DBIx::Class ODBC storage.
See DBIx::Class::Schema::Loader::Base for usage information.
DBIx::Class::Schema::Loader::DBI::ODBC::Microsoft_SQL_Server, DBIx::Class::Schema::Loader::DBI::ODBC::SQL_Anywhere, DBIx::Class::Schema::Loader::DBI::ODBC::Firebird, DBIx::Class::Schema::Loader, DBIx::Class::Schema::Loader::Base, DBIx::Class::Schema::Loader::DBI
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
| DBIx-Class-Schema-Loader documentation | Contained in the DBIx-Class-Schema-Loader distribution. |
package DBIx::Class::Schema::Loader::DBI::ODBC; use strict; use warnings; use base 'DBIx::Class::Schema::Loader::DBI'; use mro 'c3'; use Carp::Clan qw/^DBIx::Class/; use namespace::clean; our $VERSION = '0.07010';
sub _rebless { my $self = shift; return if ref $self ne __PACKAGE__; # stolen from DBIC ODBC storage my $dbh = $self->schema->storage->dbh; my $dbtype = eval { $dbh->get_info(17) }; unless ( $@ ) { # Translate the backend name into a perl identifier $dbtype =~ s/\W/_/gi; my $class = "DBIx::Class::Schema::Loader::DBI::ODBC::${dbtype}"; if ($self->load_optional_class($class) && !$self->isa($class)) { bless $self, $class; $self->_rebless; } } } sub _tables_list { my ($self, $opts) = @_; return $self->next::method($opts, undef, undef); }
1;