From: Rafael Kitover Date: Wed, 19 Jan 2011 21:40:24 +0000 (-0500) Subject: improve bare ODBC dsn warning X-Git-Tag: v0.08191~111 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=a469c0453b89a1cd45e66e35f3a25a200d9f065f;p=dbsrgits%2FDBIx-Class.git improve bare ODBC dsn warning --- diff --git a/lib/DBIx/Class/Storage/DBI/ODBC/Microsoft_SQL_Server.pm b/lib/DBIx/Class/Storage/DBI/ODBC/Microsoft_SQL_Server.pm index 34bb76b..eef33fe 100644 --- a/lib/DBIx/Class/Storage/DBI/ODBC/Microsoft_SQL_Server.pm +++ b/lib/DBIx/Class/Storage/DBI/ODBC/Microsoft_SQL_Server.pm @@ -126,8 +126,9 @@ sub connect_call_use_mars { } if (my ($data_source) = $dsn =~ /^dbi:ODBC:([\w-]+)\z/i) { # prefix with DSN - warn "Bare DSN in ODBC connect string, rewriting to DSN=$data_source\n"; - $dsn = "dbi:ODBC:DSN=$data_source"; + warn "Bare DSN in ODBC connect string, rewriting as 'dsn=$data_source'" + ." for MARS\n"; + $dsn = "dbi:ODBC:dsn=$data_source"; } $self->_dbi_connect_info->[0] = "$dsn;MARS_Connection=Yes";