sub _tables_list {
my $self = shift;
+ my ($table, $type) = @_ ? @_ : ('%', '%');
+
my $dbh = $self->schema->storage->dbh;
- my @tables = $dbh->tables(undef, $self->db_schema, '%', '%');
+ my @tables = $dbh->tables(undef, $self->db_schema, $table, $type);
s/\Q$self->{_quoter}\E//g for @tables;
s/^.*\Q$self->{_namesep}\E// for @tables;
our $VERSION = '0.04999_06';
+=head1 NAME
+
+DBIx::Class::Schema::Loader::DBI::ODBC - L<DBD::ODBC> proxy, currently only for
+Microsoft SQL Server
+
+=head1 DESCRIPTION
+
+Reblesses into L<DBIx::Class::Schema::Loader::DBI::ODBC::Microsoft_SQL_Server>,
+which is a proxy for L<DBIx::Class::Schema::Loader::DBI::MSSQL> when using the
+L<DBD::ODBC> driver with Microsoft SQL Server.
+
+Code stolen from the L<DBIx::Class> ODBC storage.
+
+See L<DBIx::Class::Schema::Loader::Base> for usage information.
+
+=cut
+
sub _rebless {
my $self = shift;
my $dbh = $self->schema->storage->dbh;
-# stolen from DBIC ODBC driver for MSSQL
+# stolen from DBIC ODBC storage
my $dbtype = eval { $dbh->get_info(17) };
unless ( $@ ) {
# Translate the backend name into a perl identifier
}
}
+=head1 SEE ALSO
+
+L<DBIx::Class::Schema::Loader::DBI::ODBC::Microsoft_SQL_Server>,
+L<DBIx::Class::Schema::Loader::DBI::MSSQL>,
+L<DBIx::Class::Schema::Loader>, L<DBIx::Class::Schema::Loader::Base>,
+L<DBIx::Class::Schema::Loader::DBI>
+
+=head1 AUTHOR
+
+Rafael Kitover C<rkitover@cpan.org>
+
+=cut
+
1;
package DBIx::Class::Schema::Loader::DBI::ODBC::Microsoft_SQL_Server;
+use strict;
+use warnings;
use base 'DBIx::Class::Schema::Loader::DBI::MSSQL';
+use Carp::Clan qw/^DBIx::Class/;
+use Class::C3;
+
+our $VERSION = '0.04999_06';
+
+=head1 NAME
+
+DBIx::Class::Schema::Loader::DBI::ODBC::Microsoft_SQL_Server - ODBC wrapper for
+L<DBIx::Class::Schema::Loader::DBI::MSSQL>
+
+=head1 DESCRIPTION
+
+Proxy for L<DBIx::Class::Schema::Loader::DBI::MSSQL> when using L<DBD::ODBC>.
+
+See L<DBIx::Class::Schema::Loader::Base> for usage information.
+
+=cut
sub _tables_list {
my $self = shift;
- my $dbh = $self->schema->storage->dbh;
- my @tables = $dbh->tables(undef, $self->db_schema);
- s/\Q$self->{_quoter}\E//g for @tables;
- s/^.*\Q$self->{_namesep}\E// for @tables;
-
- return @tables;
+ return $self->next::method(undef, undef);
}
+=head1 SEE ALSO
+
+L<DBIx::Class::Schema::Loader::DBI::MSSQL>,
+L<DBIx::Class::Schema::Loader>, L<DBIx::Class::Schema::Loader::Base>,
+L<DBIx::Class::Schema::Loader::DBI>
+
+=head1 AUTHOR
+
+Rafael Kitover C<rkitover@cpan.org>
+
+=cut
+
1;