File tree Expand file tree Collapse file tree 3 files changed +6
-20
lines changed
lib/active_record/connection_adapters/sqlserver/core_ext Expand file tree Collapse file tree 3 files changed +6
-20
lines changed Original file line number Diff line number Diff line change 14
14
fail-fast : false
15
15
matrix :
16
16
ruby :
17
- - 2.7.7
18
17
- 3.1.3
19
18
- 3.2.1
20
19
Original file line number Diff line number Diff line change
1
+ ## Unreleased
2
+
3
+ #### Changed
4
+
5
+ - [ #1200 ] ( https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/pull/1200 ) Remove ActiveRecord::Relation#calculate patch
6
+
1
7
## v7.0.6
2
8
3
9
#### Added
Original file line number Diff line number Diff line change @@ -8,25 +8,6 @@ module ConnectionAdapters
8
8
module SQLServer
9
9
module CoreExt
10
10
module Calculations
11
- # Same as original except we don't perform PostgreSQL hack that removes ordering.
12
- def calculate ( operation , column_name )
13
- return super unless klass . connection . adapter_name == "SQLServer"
14
-
15
- if has_include? ( column_name )
16
- relation = apply_join_dependency
17
-
18
- if operation . to_s . downcase == "count"
19
- unless distinct_value || distinct_select? ( column_name || select_for_count )
20
- relation . distinct!
21
- relation . select_values = [ klass . primary_key || table [ Arel . star ] ]
22
- end
23
- end
24
-
25
- relation . calculate ( operation , column_name )
26
- else
27
- perform_calculation ( operation , column_name )
28
- end
29
- end
30
11
31
12
private
32
13
You can’t perform that action at this time.
0 commit comments