File tree 1 file changed +8
-2
lines changed
lib/active_record/connection_adapters
1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -243,7 +243,7 @@ def active?
243
243
end
244
244
245
245
def reconnect
246
- @raw_connection . close rescue nil
246
+ @raw_connection & .close rescue nil
247
247
@raw_connection = nil
248
248
@spid = nil
249
249
@collation = nil
@@ -254,7 +254,7 @@ def reconnect
254
254
def disconnect!
255
255
super
256
256
257
- @raw_connection . close rescue nil
257
+ @raw_connection & .close rescue nil
258
258
@raw_connection = nil
259
259
@spid = nil
260
260
@collation = nil
@@ -338,6 +338,12 @@ def get_database_version # :nodoc:
338
338
version_year
339
339
end
340
340
341
+ def check_version # :nodoc:
342
+ if schema_cache . database_version < 2012
343
+ raise "Your version of SQL Server (#{ database_version } ) is too old. SQL Server Active Record supports 2012 or higher."
344
+ end
345
+ end
346
+
341
347
class << self
342
348
protected
343
349
You can’t perform that action at this time.
0 commit comments