From: Rafael Kitover Date: Sun, 23 May 2010 05:20:07 +0000 (-0400) Subject: release X-Git-Tag: 0.07000^0 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=b1d11550f638228695e0ce1120352bfae3c00be5;p=dbsrgits%2FDBIx-Class-Schema-Loader.git release --- diff --git a/Changes b/Changes index 001c0c4..6c286b3 100644 --- a/Changes +++ b/Changes @@ -1,6 +1,7 @@ Revision history for Perl extension DBIx::Class::Schema::Loader - - added 'qualify_objects' option to prepend db_schema to table names +0.07000 2010-05-22 23:40:15 + - added qualify_objects option to prepend db_schema to table names - fix for negative numeric default values - sequence is detected for Oracle - fix for SQLite is_auto_increment detection when table is empty (hobbs) diff --git a/lib/DBIx/Class/Schema/Loader/Base.pm b/lib/DBIx/Class/Schema/Loader/Base.pm index fd06499..28d2bac 100644 --- a/lib/DBIx/Class/Schema/Loader/Base.pm +++ b/lib/DBIx/Class/Schema/Loader/Base.pm @@ -1508,7 +1508,12 @@ sub _setup_src_meta { $table_name = \ $self->_quote_table_name($table_name); } - $self->_dbic_stmt($table_class, 'table', ($self->qualify_objects ? ($self->db_schema . '.') : '') . $table_name); + my $full_table_name = ($self->qualify_objects ? ($self->db_schema . '.') : '') . (ref $table_name ? $$table_name : $table_name); + + # be careful to not create refs Data::Dump can "optimize" + $full_table_name = \do {"".$full_table_name} if ref $table_name; + + $self->_dbic_stmt($table_class, 'table', $full_table_name); my $cols = $self->_table_columns($table); my $col_info = $self->__columns_info_for($table); diff --git a/t/16mssql_common.t b/t/16mssql_common.t index 97ddc1c..7737441 100644 --- a/t/16mssql_common.t +++ b/t/16mssql_common.t @@ -36,6 +36,8 @@ my $tester = dbixcsl_common_tests->new( password => $odbc_password, } : ()), ], + preserve_case_mode_is_exclusive => 1, + quote_char => [ qw/[ ]/ ], data_types => { # http://msdn.microsoft.com/en-us/library/ms187752.aspx