Skip to content

Commit 6e75574

Browse files
authored
TinyTDS v3+ is now required (#1273)
1 parent a06eeb4 commit 6e75574

File tree

3 files changed

+5
-6
lines changed

3 files changed

+5
-6
lines changed

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
11
## Unreleased
22

3+
#### Changed
4+
5+
- [#1273](https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/pull/1273) TinyTDS v3+ is now required.
6+
37

48
Please check [8-0-stable](https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/blob/8-0-stable/CHANGELOG.md) for previous changes.

activerecord-sqlserver-adapter.gemspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,5 +28,5 @@ Gem::Specification.new do |spec|
2828
spec.require_paths = ["lib"]
2929

3030
spec.add_dependency "activerecord", "~> 8.1.0.alpha"
31-
spec.add_dependency "tiny_tds"
31+
spec.add_dependency "tiny_tds", "~> 3"
3232
end

lib/active_record/connection_adapters/sqlserver/database_statements.rb

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -461,13 +461,8 @@ def finish_statement_handle(handle)
461461
handle
462462
end
463463

464-
# TinyTDS returns false instead of raising an exception if connection fails.
465-
# Getting around this by raising an exception ourselves while PR
466-
# https://github.com/rails-sqlserver/tiny_tds/pull/469 is not released.
467464
def internal_raw_execute(sql, raw_connection, perform_do: false)
468465
result = raw_connection.execute(sql)
469-
raise TinyTds::Error, "failed to execute statement" if result.is_a?(FalseClass)
470-
471466
perform_do ? result.do : result
472467
end
473468
end

0 commit comments

Comments
 (0)