activerecord-oracle_enhanced-adapter 5.2.8 → 7.0.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (56) hide show
  1. checksums.yaml +4 -4
  2. data/History.md +390 -21
  3. data/README.md +35 -8
  4. data/VERSION +1 -1
  5. data/lib/active_record/connection_adapters/emulation/oracle_adapter.rb +1 -1
  6. data/lib/active_record/connection_adapters/oracle_enhanced/column.rb +3 -3
  7. data/lib/active_record/connection_adapters/oracle_enhanced/connection.rb +42 -37
  8. data/lib/active_record/connection_adapters/oracle_enhanced/context_index.rb +59 -60
  9. data/lib/active_record/connection_adapters/oracle_enhanced/database_limits.rb +5 -10
  10. data/lib/active_record/connection_adapters/oracle_enhanced/database_statements.rb +86 -81
  11. data/lib/active_record/connection_adapters/oracle_enhanced/database_tasks.rb +9 -10
  12. data/lib/active_record/connection_adapters/oracle_enhanced/dbms_output.rb +1 -2
  13. data/lib/active_record/connection_adapters/oracle_enhanced/jdbc_connection.rb +37 -16
  14. data/lib/active_record/connection_adapters/oracle_enhanced/jdbc_quoting.rb +1 -1
  15. data/lib/active_record/connection_adapters/oracle_enhanced/lob.rb +5 -6
  16. data/lib/active_record/connection_adapters/oracle_enhanced/oci_connection.rb +58 -49
  17. data/lib/active_record/connection_adapters/oracle_enhanced/oci_quoting.rb +1 -1
  18. data/lib/active_record/connection_adapters/oracle_enhanced/procedures.rb +6 -7
  19. data/lib/active_record/connection_adapters/oracle_enhanced/quoting.rb +75 -51
  20. data/lib/active_record/connection_adapters/oracle_enhanced/schema_creation.rb +13 -14
  21. data/lib/active_record/connection_adapters/oracle_enhanced/schema_definitions.rb +14 -4
  22. data/lib/active_record/connection_adapters/oracle_enhanced/schema_dumper.rb +27 -24
  23. data/lib/active_record/connection_adapters/oracle_enhanced/schema_statements.rb +156 -155
  24. data/lib/active_record/connection_adapters/oracle_enhanced/structure_dump.rb +103 -90
  25. data/lib/active_record/connection_adapters/oracle_enhanced/type_metadata.rb +3 -2
  26. data/lib/active_record/connection_adapters/oracle_enhanced_adapter.rb +261 -161
  27. data/lib/active_record/type/oracle_enhanced/boolean.rb +0 -1
  28. data/lib/active_record/type/oracle_enhanced/character_string.rb +36 -0
  29. data/lib/active_record/type/oracle_enhanced/integer.rb +0 -1
  30. data/lib/arel/visitors/oracle.rb +221 -0
  31. data/lib/arel/visitors/oracle12.rb +128 -0
  32. data/spec/active_record/connection_adapters/emulation/oracle_adapter_spec.rb +0 -2
  33. data/spec/active_record/connection_adapters/oracle_enhanced/connection_spec.rb +78 -26
  34. data/spec/active_record/connection_adapters/oracle_enhanced/context_index_spec.rb +7 -15
  35. data/spec/active_record/connection_adapters/oracle_enhanced/database_tasks_spec.rb +5 -0
  36. data/spec/active_record/connection_adapters/oracle_enhanced/dbms_output_spec.rb +17 -17
  37. data/spec/active_record/connection_adapters/oracle_enhanced/procedures_spec.rb +7 -10
  38. data/spec/active_record/connection_adapters/oracle_enhanced/quoting_spec.rb +0 -15
  39. data/spec/active_record/connection_adapters/oracle_enhanced/schema_dumper_spec.rb +33 -36
  40. data/spec/active_record/connection_adapters/oracle_enhanced/schema_statements_spec.rb +77 -258
  41. data/spec/active_record/connection_adapters/oracle_enhanced/structure_dump_spec.rb +38 -39
  42. data/spec/active_record/connection_adapters/oracle_enhanced_adapter_spec.rb +273 -85
  43. data/spec/active_record/connection_adapters/oracle_enhanced_data_types_spec.rb +7 -8
  44. data/spec/active_record/oracle_enhanced/type/boolean_spec.rb +2 -4
  45. data/spec/active_record/oracle_enhanced/type/character_string_spec.rb +43 -0
  46. data/spec/active_record/oracle_enhanced/type/custom_spec.rb +90 -0
  47. data/spec/active_record/oracle_enhanced/type/decimal_spec.rb +56 -0
  48. data/spec/active_record/oracle_enhanced/type/dirty_spec.rb +1 -1
  49. data/spec/active_record/oracle_enhanced/type/integer_spec.rb +2 -2
  50. data/spec/active_record/oracle_enhanced/type/json_spec.rb +0 -1
  51. data/spec/active_record/oracle_enhanced/type/national_character_string_spec.rb +6 -5
  52. data/spec/active_record/oracle_enhanced/type/timestamp_spec.rb +2 -4
  53. data/spec/spec_config.yaml.template +2 -2
  54. data/spec/spec_helper.rb +13 -2
  55. metadata +52 -30
  56. data/lib/active_record/connection_adapters/oracle_enhanced/schema_statements_ext.rb +0 -28
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: aa24e2267bec0862bb898b8f03c11af04a34543d38f75e8b39a5b46000009437
4
- data.tar.gz: '0485525d25c1f4307c1e9b958cd2f1b286bc5d10542e2fd8615e499a00c989c2'
3
+ metadata.gz: 9b4ee27d979189b61c88f8183180b3de5fddc6f5332300594090b7b264bb79e5
4
+ data.tar.gz: 1edc6fff9695c7fec045eb376fc2dbcef414182705c4873901423e241abceb05
5
5
  SHA512:
6
- metadata.gz: e70d58d735fec37fd8e19122f37b284397f152c911e3baf8127d8828cefd7b9f139d1acf2f3e147def7c82be26decd7e4f4eb10e85e63489ef6933ab089f83b7
7
- data.tar.gz: 5651ab5ab00219a433b7281959d51068ea47dcd33648761cd4dc4f22c69f285dd79a8c73e262fdabe81042e9751dcb02021392c472649f7662b593daf1187d60
6
+ metadata.gz: de56825206be9a3aec2102ed337c575b347837be940ffeccce2fdc5ae6cf960d2ebc4514be723a1f497544d90f147f9aeab0da657f5d06727ea970ebb2fe7647
7
+ data.tar.gz: 3e98d015c3761733287706d85d79e73b53c2dbf7644ddfbb95f0adf70c07ec49b212b05b003bd50938688d5b6d527ea3817d74ff6091b9e2eb72099ede368c45
data/History.md CHANGED
@@ -1,21 +1,390 @@
1
- ## 5.2.8 / 2019-12-25
1
+ ## 7.0.3 / 2023-08-10
2
2
 
3
3
  * Changes and bug fixes
4
- * Uninstall SimpleCov [#1968 #1970]
4
+ * Support Rails 7.0.7
5
+ * Make ActiveRecord's quoted name caches thread-safe on JRuby/TruffleRuby [#2347, #2346]
6
+ * Address `NameError: uninitialized constant TestEmployee::AttributeSignature::Base64` [#2347]
7
+ * Address `Style/RedundantRegexpEscape` offense [#2347]
5
8
 
6
- ## 5.2.7 / 2019-12-20
9
+ ## 7.0.2 / 2022-01-21
7
10
 
8
11
  * Changes and bug fixes
9
- * Address undefined local variable or method sql' [#1932 #1962 #1964]
12
+ * Fix `columns_for_distinct` when using Rails 6.1 [#2249 #2251 rails/rails#31966]
13
+
14
+ ## 7.0.1 / 2022-01-13
15
+
16
+ * Changes and bug fixes
17
+ * Add ruby-oci8 as dependency only for CRuby [#2238 #2240 #2243]
18
+ * Add if_exists option to remove_index [#2219 #2233]
19
+ * all attributes serialized before writing [#2203 #2234]
20
+ * Require 'activerecord', not 'rails' not to attempt to install digest [#2241]
21
+ * CI
22
+ * Bump Ruby versions at Travis CI [#2242]
23
+ * CI against Ruby 3.1 at GitHub Actions [#2235 #2244]
24
+ ## 7.0.0 / 2021-12-16
25
+ * Changes and bug fixes
26
+ * Support Rails 7.0.0
27
+
28
+ ## 7.0.0.rc1 / 2021-12-08
29
+
30
+ * Changes and bug fixes
31
+ * Support Rails 7.0.0.rc1
32
+ * Rails 7 requires Ruby 2.7 and prefer Ruby 3+ [#2136]
33
+ * Allow usage of JDBC statement caching by DB config parameter [#2088]
34
+ * structure dump: read column comments from all_tab_cols [#2121]
35
+ * Usage of bind variables for volatile filter conditions (3) [#2125]
36
+ * attribute should not require a connection is established [#2136]
37
+ * Allow Adapter#select_all to be performed asynchronously from a background thread pool [#2146]
38
+ * Avoid extra BindParam allocation to generate placeholder in queries [#2157]
39
+ * Address undefined method `to_i' for #<ActiveModel::Attribute::WithCastValue [#2159]
40
+ * Update Rails default branch name change [#2126]
41
+ * Optimize remove_columns to use a single SQL statement when supported [#2182]
42
+ * Refactor schema creation to extract new_foreign_key_definition [#2183]
43
+ * Address "NoMethodError: undefined method `partial_writes?'" [#2188]
44
+ * Suppress partial_writes deprecation warning [#2189]
45
+ * Make default_timezone a module instance variable [#2190]
46
+ * Define adapter type maps statically when possible [#2199]
47
+ * Rename _type_cast to type_cast [#2199]
48
+ * Rename _quote to quote [#2199]
49
+ * Always use OpenSSL constants for Digest operations [#2217]
50
+ * Refactor ActiveRecord::QueryLogs hook point [#2218]
51
+ * Enable Style/RedundantRegexpEscape cop [#2074]
52
+ * Enable Lint/DuplicateRequire cop [#2107]
53
+ * Enable Layout/SpaceBeforeBrackets cop [#2108]
54
+ * Enable Performance/BindCall cop [#2140]
55
+ * Enable Performance/StringReplacement cop [#2175]
56
+ * Enable Performance/MapCompact cop [#2176]
57
+ * Enable Layout/EndOfLine cop [#2177]
58
+ * Enable Performance/SelectMap cop [#2178]
59
+ * Enable Layout/ClosingParenthesisIndentation cop [#2193]
60
+ * Enable Style/ExplicitBlockArgument cop [#2209]
61
+ * Enable Lint/DuplicateMethods cop [#2215]
62
+ * Disable Lint/ShadowingOuterLocalVariable cop [#2137]
63
+ * Disable Layout/FirstArgumentIndentation cop [#2149]
64
+ * Opt out of SuggestExtensions message [#2133]
65
+ * Suppress RuboCop's offense [#2196]
66
+ * Support RuboCop 1.19.0 [#2204]
67
+ * Prevent from including ojdbc8.jar file to gem file [#2164]
68
+
69
+ * CI
70
+ * Disable CI against JRuby builds [#2136]
71
+ * CI against Ruby 3.0.0 [#2091]
72
+ * CI against Ruby 3.0.1 and 2.7.3 [#2173]
73
+ * CI against Ruby 3.0.2 and 2.7.4 [#2195]
74
+ * Exclude ruby-head and ruby-debug until minitest allows Ruby 3.1 [#2094]
75
+ * Address Travis CI warnings and bump Ubuntu version to 20.04 [#2086]
76
+ * Tidy up Travis CI configuration [#2116]
77
+ * Tweak representation of build matrix [#2129]
78
+ * Install Oracle JDBC driver ojdbc11.jar for GitHub Actions [#2172]
79
+ * Address guides/bug_report_templates/active_record_gem_spec.rb error [#2101]
80
+ * Use Oracle Instant Client 21.1.0.0.0 [#2205]
81
+ * Use Oracle Instant Client 21.4 [#2199]
82
+ * Use gvenzl/oracle-xe docker image [#2206]
83
+
84
+ ## 6.1.5 / 2021-12-07
85
+
86
+ * Changes and bug fixes
87
+ * get root cause if something went wrong with jdbc.OracleDriver [#2180 #2181]
88
+
89
+ * CI
90
+ * Bump CRuby versions at Travis CI for release61 branch [#2192]
91
+
92
+ ## 6.1.4 / 2021-04-01
93
+
94
+ * Changes and bug fixes
95
+ * Support use of ojdbc11.jar [#2155, #2168]
96
+ * Add missing default granted permission "ulimited tablespace" [#2156, #2167]
97
+ * Prevent from including ojdbc8.jar file to gem file [#2163, #2164, #2165]
98
+ * Oracle enhanced adapter 6.1.3 has been yanked since #2163
99
+
100
+ * CI
101
+ * Allow-failure CI against jruby-head for release61 branch [#2166]
102
+
103
+ ## 6.1.3 / 2021-03-31
104
+
105
+ * Changes and bug fixes
106
+ * Address FrozenError (can't modify frozen Hash): error [#2139 #2151 #2160]
107
+
108
+ * CI
109
+ * CI against JRuby 9.2.15.0 [#2150]
110
+
111
+ ## 6.1.2 / 2021-02-10
112
+ * Changes and bug fixes
113
+ * Fixed ORA-01935: missing user or role name with config read issue [#1943 #2135, #2142]
114
+
115
+ ## 6.1.1 / 2021-01-14
116
+
117
+ * Changes and bug fixes
118
+ * Remove /*+ OPTIMIZER_FEATURES_ENABLE('11.2.0.2') */ hint for all_synonyms [#2110, #2119]
119
+ * Fix write_lobs Invalid byte sequence in UTF-8 [#2097, #2111]
120
+ * Ensure FKs are properly included in structure dumps [#2109, #2113]
121
+
122
+ * CI
123
+ * CI against JRuby 9.2.14.0 [#2085]
124
+ * CI against Ruby 3.0.0 [#2091, #2092]
125
+ * Address Travis CI warnings and bump Ubuntu version to 20.04 [#2086]
126
+ * Exclude `ruby-head` and `ruby-debug` until minitest allows Ruby 3.1 #2094, #2095
127
+ * CI against Ruby 3.0.0 at Travis CI [#2093]
128
+
129
+ ## 6.1.0 / 2020-12-15
130
+
131
+ * Changes and bug fixes
132
+ * Support Rails 6.1.0
133
+ * Update bug report templates for Oracle enhanced adapter 6.1 [#2063]
134
+ * Use released version of rake [#2065 #2066]
135
+ * Add /*+ OPTIMIZER_FEATURES_ENABLE('11.2.0.2') */ hint to address slow SCHEMA queries [#2055, #2068]
136
+ * `build_subselect` does not have ordering [#2070]
137
+ * Remove `visit_Arel_Nodes_NotIn` and `visit_Arel_Nodes_In` visitors [#2075, #2077]
138
+ * `NOT IN` clause needs separated by `AND` [#2079, #2081]
139
+
140
+ ## 6.1.0.rc1 / 2020-11-03
141
+
142
+ * Changes and bug fixes
143
+ * Support Rails 6.1.0.rc1
144
+ * Add support to change the permissions granted when creating DB [#1885]
145
+ * Refactor `create_table`'s options separation [#1886]
146
+ * Move schema cache to pool [#1888]
147
+ * Clear schema cache when a table is created/dropped/renamed [#1891]
148
+ * Deduplicate various Active Record schema cache structures [#1897]
149
+ * Support SQLCounter change to ignore "SCHEMA" and "TRANSACTION" log [#1892]
150
+ * Share the column and table name quote cache between connections [#1901]
151
+ * Add database_exists? method to connection adapters [#1906]
152
+ * Accept columns passed with options in remove_index [#1930]
153
+ * Fix `NameError` for `SchemaCreation` [#1933]
154
+ * Add `supports_common_table_expressions?` for CTE testing [#1946]
155
+ * create_table_definition and add_column take keyword arguments [#1942]
156
+ * Address `uninitialized constant ActiveRecord::ConnectionAdapters::AbstractAdapter::Quoting (NameError) [#1950]
157
+ * Fix an error when writing lobs [#1962]
158
+ * Uninstall SimpleCov [#1968]
159
+ * fix: Auto retry only works for connection.exec() [#1976]
160
+ * Fix keyword arguments errors for Ruby 2.8.0-dev [#1977]
161
+ * Fix a build errors when using Ruby 2.8.0-dev [#1983]
162
+ * Include sync option when dumping a context index [#1988]
163
+ * Use `build_result` instead of `ActiveRecord::Result.new` [#1994]
164
+ * Use the new API for build_results [#1995]
165
+ * Merge Arel visitors [#2002]
166
+ * Enable `Rails/IndexBy` and `Rails/IndexWith` cops [#2006]
167
+ * Don't refer `allowed_index_name_length` directly [#2009]
168
+ * Should not rely on the global `Arel::Table.engine` in the framework [#2010]
169
+ * Suppress `warning: already initialized constant` [#2011]
170
+ * Deprecate passing a column to `type_cast` [#2012]
171
+ * Limit number of expressions in a list during a "homogenous in" operation [#2013]
172
+ * Allow column name with function (e.g. `length(title)`) as safe SQL string [#2017]
173
+ * Default engine `ENGINE=InnoDB` is no longer dumped to make schema more agnostic [#2019]
174
+ * Separate primary key column options from table options [#2019]
175
+ * Make index options to kwargs [#2022]
176
+ * Make remaining migration options to kwargs [#2024]
177
+ * Allow TruffleRuby RUBY_ENGINE [#2046]
178
+ * Restore Schema Dumper behavior changed by #2019 [#2047]
179
+ * Support JDBC service name syntax [#2035]
180
+ * Use Rake 13.0.0.pre.1 [#1924]
181
+ * Bump RuboCop version to 0.71 [#1887]
182
+ * Bump RuboCop to 0.74.0 [#1914]
183
+ * Bump RuboCop to 0.76.0 [#1947]
184
+ * Use RuboCop 0.77 [#1959]
185
+ * Bump RuboCop to 0.82.0 [#2005]
186
+ * Suppress RuboCop's offenses [#2020]
187
+ * Enable `Layout/EmptyLinesAroundAccessModifier` cop [#1890]
188
+ * Disable `Style/BracesAroundHashParameters` cop [#1923]
189
+ * Enable `Layout/ClosingHeredocIndentation` cop [#1958]
190
+ * Unlock RuboCop gem versions [#1926]
191
+ * Enable `Rails/IndexBy` and `Rails/IndexWith` cops [#2006]
192
+ * Enable `Performance/DeletePrefix` and `Performance/DeleteSuffix` cops [#2021]
193
+ * Enable `Layout/SpaceAroundOperators` cop [#2057]
194
+ * Fix links to rails-dev-box running on docker [#1883]
195
+ * Fix spec config template copy instructions [#1884]
196
+ * Update UPGRADE section for Rails 5.2 [#1993]
197
+
198
+ * CI
199
+ * Enable GitHub Actions and run RuboCop [#1925]
200
+ * Run CI with GitHub Actions [#2015]
201
+ * Enabled Dependabot by creating .dependabot/config.yml [#1931]
202
+ * Disable Code Climate #1938
203
+ * CI against JRuby 9.2.8.0 [#1911]
204
+ * CI against JRuby 9.2.9.0 #1948
205
+ * CI against Ruby 2.6.4 and Ruby 2.5.6 [#1921]
206
+ * CI against Ruby 2.5.7 and Ruby 2.6.5 [#1949]
207
+ * CI against Ruby 2.7.0 [#1975]
208
+ * CI against JRuby 9.2.10.0 [#1989]
209
+ * CI against JRuby 9.2.11.0 [#1992]
210
+ * CI against JRuby 9.2.11.1 [#1997]
211
+ * CI againt Ruby 2.7.1, 2.6.6 and 2.5.8 #1998
212
+ * CI against JRuby 9.2.12.0 [#2034]
213
+ * Use Oracle Instant Client 18.5 [#2036]
214
+ * Support `jruby-head` again [#2037]
215
+ * CI against JRuby 9.2.13.0 [#2041]
216
+ * CI against Ruby 2.7.2 [#2052]
217
+ * Remove unnecessary PATH and LD_LIBRARY_PATH environment variables [#1927]
218
+ * Use Ubuntu 18.04 (Bionic Beaver) at Travis CI [#1937]
219
+ * Run bug report template at CI [#1936]
220
+ * Skip known failures until #1943 is resolved [#1961]
221
+ * Migrate to `ruby/setup-ruby` to use Ruby 2.7 [#2026]
222
+
223
+ ## 6.0.4 / 2020-08-18
224
+
225
+ * Changes and bug fixes
226
+ * create_table_definition and add_column take keyword arguments [#1942, #2043]
227
+ * Fix keyword arguments errors for Ruby 2.8.0-dev [#1977,#2043]
228
+ * Fix a build errors when using Ruby 2.8.0-dev [#1983, #2043]
229
+
230
+ ## 6.0.3 / 2020-06-16
231
+
232
+ * Changes and bug fixes
233
+ * Auto retry works for other `exec_*` methods [#1976, #1981]
234
+ * Allow column name with function (e.g. `length(title)`) as safe SQL string [#2017, #2018]
235
+
236
+ * CI
237
+ * CI against latest Ruby versions [#1979]
238
+
239
+ ## 6.0.2 / 2019-12-25
240
+
241
+ * Changes and bug fixes
242
+ * Uninstall SimpleCov [#1968]
243
+
244
+ ## 6.0.1 / 2019-12-20
245
+
246
+ * Changes and bug fixes
247
+ * Address `undefined local variable or method `sql' [#1932 #1962 #1963]
248
+
249
+ * CI
10
250
  * CI against Ruby 2.6.4 and Ruby 2.5.6 [#1922]
11
- * Lock simplecov version for Ruby 2.2 and 2.3 [#1902]
12
251
 
13
- ## 5.2.6 / 2019-05-17
252
+ ## 6.0.0 / 2019-08-17
253
+
254
+ * Major changes, including changes since 6.0.0.beta1
255
+
256
+ * Support Rails 6.0.0
257
+ * Rails 6 requires Ruby 2.5 [#1801]
258
+ * Support longer identifier for Oracle database 12.2 or higher [#1703 #1705]
259
+ * Introduce `use_shorter_identifier` [#1707]
260
+ * Change `default_sequence_start_value` from 10000 to 1 [#1636]
261
+ * Address `ORA-01795: maximum number of expressions in a list is 1000`
262
+
263
+ * CI
264
+ * CI against JRuby 9.2.8.0 #1912
265
+
266
+ ## 6.0.0.rc3 / 2019-07-27
267
+
268
+ * Changes and bug fixes
269
+ * Share the column and table name quote cache between connections [#1901 #1903]
270
+
271
+ ## 6.0.0.rc2 / 2019-07-23
272
+
273
+ * Major changes
274
+ * Support Rails 6.0.0 rc2
275
+ * Add TCP keepalive and TCP keepalive time configurations [#1874 #1877]
276
+
277
+ * Changes and bug fixes
278
+ * Update bug report templates for Oracle enhanced adapter 6.0 [#1873]
279
+
280
+ ## 6.0.0.rc1 / 2019-04-25
281
+
282
+ * Major changes
283
+ * Support Rails 6.0.0 rc1
284
+ * Address `ORA-01795: maximum number of expressions in a list is 1000`
285
+ - These changes has been made to Rails itself [rails/rails#35838, rails/rails#36074]
286
+
287
+ * Changes and bug fixes
288
+ * Cache database version in schema cache [#1859]
289
+ * Except `table_name` from column objects [#1860]
290
+ * Remove unused `sequence_name` in `sql_for_insert` [#1861]
291
+ * Use squiggly heredoc to strip odd indentation in the executed SQL [#1869]
292
+ * Use Active Support `String#squish` instead of `String#strip.gsub` [#1871]
293
+
294
+ * CI
295
+ * Revert "Add `allow_railures` for jruby-head until #1833 resolved" [#1862]
296
+ * CI against JRuby 9.2.7.0 [#1864]
297
+ * Use newer Code Climate analysis model, version 2 [#1868]
298
+ * CI against Ruby 2.6.3 [#1870]
299
+
300
+ * RuboCop
301
+ * Bump RuboCop version to 0.67 [#1867]
302
+ * Enable `Layout/SpaceBeforeComment` cop [#1863]
303
+
304
+ ## 6.0.0.beta1 / 2019-03-18
305
+
306
+ * Major changes
307
+
308
+ * Rails 6 requires Ruby 2.5 [#1801]
309
+ * Support longer identifier for Oracle database 12.2 or higher [#1703 #1705]
310
+ * Introduce `use_shorter_identifier` [#1707]
311
+ * Change `default_sequence_start_value` from 10000 to 1 [#1636]
312
+ * Supports `supports_optimizer_hints?` [#1850 #1852]
313
+ * `OracleEnhanced::SchemaStatements#tables` excludes materialized views [#1708]
314
+ * rake db:structure:dump extracts views by default [#1625 #1641]
315
+ * Drop db link support [#1668 #1681 #1696 #1706]
316
+ * Drop trigger based primary key support for Rails 6 [#1669]
317
+ * Don't allow unsupported NLS parameters [#1685]
318
+ * fix Handling with char-column problem [#1760]
319
+ * Make `t.timestamps` with precision by default [#1818]
320
+ * fix mapping of decimal type to map to `NUMBER` instead of `DECIMAL` [#1840]
14
321
 
15
322
  * Changes and bug fixes
16
- * Add TCP keepalive and TCP keepalive time configurations [#1874 #1878]
17
- * CI against Ruby 2.6.2 and 2.5.5 #1849
18
- * CI against Ruby 2.4.6 #1858
323
+
324
+ * Handle ORA-02292 as `InvalidForeignKey` [#1771]
325
+ * Suppress deprecated warning for `table_name_length` [#1772]
326
+ * `update_attributes!` will be deprecated in Rails 6 [#1665]
327
+ * `update_attributes` will be deprecated in Rails 6 [#1667]
328
+ * Remove `OCI8#describe` to use `OracleEnhanced::Connection#describe` [#1639]
329
+ * Remove `strip_heredoc` [#1652]
330
+ * Remove `rails/arel` from Gemfile [#1711]
331
+ * Remove `rails/arel` from bug report templates [skip ci] [#1715]
332
+ * Remove NativeException [#1666 #1762]
333
+ * Do not set nil value to java.util.Properties [#1763]
334
+ * Deprecated `table_name_length` and `column_name_length` [#1770]
335
+ * Add a check to supported Oracle database version [#1773]
336
+ * Update bug report templates [#1777]
337
+ * Use `supports_foreign_keys?` instead of removed `supports_foreign_keys_in_create?` [#1825]
338
+ * Ensure `clear_cache!` clears the prepared statements cache [#1845]
339
+
340
+ * Refactoring
341
+
342
+ * Extract `structure_dump_views` and `structure_dump_synonyms` [#1640]
343
+ * Remove unnecessary `respond_to?(:report_on_exception)` [#1664]
344
+ * Remove deprecated `#insert_fixtures` method for Rails 6.0 [#1815]
345
+ * Use `SYS_CONTEXT('userenv', 'current_schema')` to find schema objects [#1671]
346
+ * Use `SYS_CONTEXT('userenv', 'current_schema')` for owner [#1672]
347
+ * Suppress warning `BigDecimal.new` is deprecated [#1742]
348
+ * Refactor to initialize `TableDefinition` by kwargs [#1785]
349
+ * Redact SQL in errors [#1791]
350
+ * Arity change at `sql_for_insert` [#1814]
351
+
352
+ * CI
353
+ * Use Ubuntu Xenial at Travis CI [#1790]
354
+ * Bump Ruby versions to 2.6.2 and 2.5.4 [#1847]
355
+ * CI against Ruby 2.5.5 [#1848]
356
+ * Do not run CI against Ruby 2.2, which will not be supported with Rails 6 [#1653]
357
+ * CI against JRuby 9.2.6.0 [#1824]
358
+ * Show ruby version at CI [#1829]
359
+ * Remove unused blocklist from .travis.yml [#1830]
360
+ * Add spec for custom sequence name [#1846]
361
+ * Restore old Code Climate behavior [#1716]
362
+ * Do not install bundler explicitly [#1725]
363
+
364
+ * RuboCop
365
+
366
+ * Add RuboCop to Gemfile [#1841]
367
+ * Bump RuboCop to 0.63.0 [#1816]
368
+ * No need to exclude `jdbc_connection.rb` for `Style/ColonMethodCall` cop [#1698]
369
+ * Enable `Style/ColonMethodCall` cop [#1658]
370
+ * Enable `Lint/StringConversionInInterpolation` cop [#1724]
371
+ * Add `Style/RedundantFreeze` to remove redudant `.freeze` [#1662]
372
+ * Use `Layout/EndAlignment` cop to support RuboCop 0.54 [#1709]
373
+ * Introduced StartWith, EndWith and RegexpMatch cops [#1738]
374
+ * Enable `Layout/EmptyLinesAroundBlockBody` cop [#1732]
375
+ * Turn on performance based cops [#1734]
376
+ * Enable performance unfreeze string cop [#1729]
377
+ * Enable `Lint/UriEscapeUnescape` cop [#1758]
378
+ * Enable Style/ParenthesesAroundCondition cop [#1759]
379
+ * Enable performance unfreeze string cop [#1729]
380
+ * Enable `Layout/SpaceAfterSemicolon` cop [#1800]
381
+ * Enable `Style/RedundantBegin` cop [#1802]
382
+ * Enable `Lint/ShadowingOuterLocalVariable` cop [#1810]
383
+ * Enable `Lint/UselessAssignment` cop [#1812]
384
+ * Enable `Lint/DeprecatedClassMethods` cop [#1813]
385
+ * Enable `Lint/ErbNewArguments` cop [#1823]
386
+ * Enable `Lint/AmbiguousOperator` and `Lint/AmbiguousRegexpLiteral` cops [#1842]
387
+ * Enable `Performance/ReverseEach` cop [#1843]
19
388
 
20
389
  ## 5.2.5 / 2019-03-05
21
390
 
@@ -189,7 +558,7 @@
189
558
  * Remove `add_runtime_dependency` with arel [#1385]
190
559
  * Move methods for synonyms out of `SchemaStatementsExt` [#1387]
191
560
  * Remove incorrect prepend to `ActiveRecord::ColumnDumper` [#1394]
192
- * Handle `ActiveRecord::SchemaDumper` by `adapter_name` [#1395]
561
+ * Handle `ActiveRecord::SchemaDumper` by `adapter_name` [#1395]
193
562
  * Rewrite `remove_prefix_and_suffix` to be similar with super #1401
194
563
  * `remove_prefix_and_suffix` handles dollar sign by `Regexp#escape` [#1402]
195
564
  * `prepare_column_options` is now private [#1429]
@@ -453,7 +822,7 @@
453
822
  * Use the latest arel master while developing alpha version [#1115]
454
823
  * Bump Arel to 8.0 [#1120, #1121, #1124]
455
824
  * Use released Arel 8 [#1205]
456
- * Remove duplicate license information [#965]
825
+ * Remove duplicate license information [#965]
457
826
  * Clean up comments and un-commented specs for table comment feature [#971]
458
827
  * Use Rails migration `create_table` to create table and sequence [#991]
459
828
  * Removed a invalid spec about TIMESTAMP column [#1020]
@@ -841,7 +1210,7 @@
841
1210
  * Address `add_column_options!': undefined method `quote_value' [#647]
842
1211
  * Remove dirty tracking methods [#883]
843
1212
  * Use arel master branch for rails5 development [#645]
844
- * Bump ruby-oci8 version to 2.2.0 or higher [#775]
1213
+ * Bump ruby-oci8 version to 2.2.0 or higher [#775]
845
1214
  * Remove jeweler dependency [#766]
846
1215
  * Remove required_rubygems_version [#719]
847
1216
  * Remove journey which is already part of Rails [#701]
@@ -879,13 +1248,13 @@
879
1248
  * Rails 5 : create table with primary key trigger with default primary key not returning id [#912]
880
1249
  * Rails 5 : dirty object tracking not working correctly for CLOB [#911]
881
1250
  * Rails 5 : handling of CLOB columns get failures [#910]
882
- * Rails 5 : SQL with bind parameters when NLS_NUMERIC_CHARACTERS is set to ', '
1251
+ * Rails 5 : SQL with bind parameters when NLS_NUMERIC_CHARACTERS is set to ', '
883
1252
  show Java::JavaSql::SQLSyntaxErrorException: / ORA-01722: invalid number [#909]
884
1253
  * Rails 5 : explain should explain query with binds got Java::JavaSql::SQLException: Invalid column index [#908]
885
1254
  - CRuby and JRuby
886
1255
  * Rails 5 : create table with primary key trigger not returning id [#907]
887
1256
  * Rails 5 : custom methods for create, update and destroy not working [#906]
888
- * Rails 5 : has_and_belongs_to_many test gets ORA-01400 since primary key column "ID"
1257
+ * Rails 5 : has_and_belongs_to_many test gets ORA-01400 since primary key column "ID"
889
1258
  not included in insert statement [#856, rails/rails#25388]
890
1259
  * Rails 5 : undefined method `to_i' for #<Arel::Nodes::BindParam:0x00000002c92910> [#848, rails/arel#438]
891
1260
 
@@ -948,11 +1317,11 @@
948
1317
 
949
1318
  * Changes and bug fixes since 1.6.0
950
1319
 
951
- * Oracle enhanced adapter v1.6 requires ActiveRecord 4.2.1 or higher,
1320
+ * Oracle enhanced adapter v1.6 requires ActiveRecord 4.2.1 or higher,
952
1321
  ActiveRecord 4.2.0 is not supported.[#651, #652]
953
1322
  * Fix serialized value becomes from yaml to string once saved [#655, #657]
954
1323
  * Update Ruby version in readme [#654]
955
- * Update unit test matcher to skip sql statements to get `table` metadata [#653]
1324
+ * Update unit test matcher to skip sql statements to get `table` metadata [#653]
956
1325
 
957
1326
  ## 1.6.0 / 2015-06-25
958
1327
 
@@ -1035,7 +1404,7 @@
1035
1404
  * Change log method signiture to support Rails 4.2 [#539]
1036
1405
  * Enable loading spec configuration from config file instead of env [#550]
1037
1406
  * Rails42: Issue with non-existent columns [#545, #551]
1038
- * Squelch warning "#column_for_attribute` will return a null object
1407
+ * Squelch warning "#column_for_attribute` will return a null object
1039
1408
  for non-existent columns in Rails 5. Use `#has_attribute?`" [#551]
1040
1409
  * Use arel 6-0-stable [#565]
1041
1410
  * Support 'Y' as true and 'N' as false in Rails 4.2 [#574, #573]
@@ -1046,7 +1415,7 @@
1046
1415
  * Rails 4.2 Address ArgumentError: wrong number of arguments (1 for 2) at `quote_value` [#511]
1047
1416
  * Address ORA-00932: inconsistent datatypes: expected NUMBER got DATE [#538]
1048
1417
  * Remove duplicate alias_method_chain for indexes [#560]
1049
- * Address RangeError: 6000000000 is out of range for ActiveRecord::Type::Integer
1418
+ * Address RangeError: 6000000000 is out of range for ActiveRecord::Type::Integer
1050
1419
  with limit 4 [#578]
1051
1420
  * Return foreign_keys_without_oracle_enhanced when non Oracle database used [#583]
1052
1421
  * Add missing database_tasks.rb to gemspec [#585]
@@ -1091,7 +1460,7 @@
1091
1460
  * Enhancements
1092
1461
  * Oracle NUMBER datatype can be handled as Rails :float datatype [#418]
1093
1462
  - Default NUMBER datatype handled as :decimal to keep compatibility
1094
- - Configured by setting `self.number_datatype_coercion = :float`
1463
+ - Configured by setting `self.number_datatype_coercion = :float`
1095
1464
  * Add link to supported Oracle database version, JDK and Oracle JDBC Driver version [#438]
1096
1465
  * Support `without_prepared_statements?` to handle `unprepared_statement` [#447]
1097
1466
 
@@ -1173,7 +1542,7 @@
1173
1542
  * Create indexes automatically for references and belongs_to [#183]
1174
1543
  * Use the index name explicitly provided in a migration when reverting [#296]
1175
1544
  * Rename indexes when a table or column is renamed [#286]
1176
- * Support refactored remove_column [#172]
1545
+ * Support refactored remove_column [#172]
1177
1546
  * Support allowed_index_name_length method [#285]
1178
1547
  * Remove schema prefix from sequence name if present before truncating [#155]
1179
1548
  * Bumped jeweler, ruby-plsql and ruby-oci8 version [#176]
@@ -1489,7 +1858,7 @@
1489
1858
  * Added support for NVARCHAR2 column type
1490
1859
  * Bug fixes:
1491
1860
  * Do not call write_lobs callback when custom create or update methods are defined
1492
-
1861
+
1493
1862
  ### 1.1.5 / 2008-07-27
1494
1863
 
1495
1864
  * Bug fixes:
data/README.md CHANGED
@@ -6,10 +6,43 @@ Oracle enhanced adapter for ActiveRecord
6
6
  DESCRIPTION
7
7
  -----------
8
8
 
9
- Oracle enhanced ActiveRecord adapter provides Oracle database access from Ruby on Rails applications. Oracle enhanced adapter can be used from Ruby on Rails versions between 2.3.x and 5.1 and it is working with Oracle database versions from 10g to 12c.
9
+ Oracle enhanced ActiveRecord adapter provides Oracle database access from Ruby on Rails applications. Oracle enhanced adapter can be used from Ruby on Rails versions between 2.3.x and 7.0 and it is working with Oracle database versions 10g and higher
10
10
 
11
11
  INSTALLATION
12
12
  ------------
13
+ ### Rails 7.0
14
+
15
+ Oracle enhanced adapter version 7.0 supports Rails 7.0
16
+ When using Ruby on Rails version 7.0 then in Gemfile include
17
+
18
+ ```ruby
19
+ # Use oracle as the database for Active Record
20
+ gem 'activerecord-oracle_enhanced-adapter', '~> 7.0.0'
21
+ gem 'ruby-oci8' # only for CRuby users
22
+ ```
23
+
24
+ ### Rails 6.1
25
+
26
+ Oracle enhanced adapter version 6.1 supports Rails 6.1.
27
+ When using Ruby on Rails version 6.1 then in Gemfile include
28
+
29
+ ```ruby
30
+ # Use oracle as the database for Active Record
31
+ gem 'activerecord-oracle_enhanced-adapter', '~> 6.1.0'
32
+ gem 'ruby-oci8' # only for CRuby users
33
+ ```
34
+
35
+ ### Rails 6.0
36
+
37
+ Oracle enhanced adapter version 6.0 supports Rails 6.0.
38
+ When using Ruby on Rails version 6.0 then in Gemfile include
39
+
40
+ ```ruby
41
+ # Use oracle as the database for Active Record
42
+ gem 'activerecord-oracle_enhanced-adapter', '~> 6.0.0'
43
+ gem 'ruby-oci8' # only for CRuby users
44
+ ```
45
+
13
46
  ### Rails 5.2
14
47
 
15
48
  Oracle enhanced adapter version 5.2 supports Rails 5.2.
@@ -652,7 +685,7 @@ if any database structure changed by migrations, execute `rails db:schema:cache:
652
685
 
653
686
  UPGRADE
654
687
  ---------------
655
- ### Upgrade Rails 5.0 or older version to Rails 5.2
688
+ ### Upgrade Rails 5.1 or older version to Rails 5.2
656
689
 
657
690
  * `emulate_booleans_from_strings = true` change
658
691
 
@@ -666,12 +699,6 @@ class Post < ActiveRecord::Base
666
699
  end
667
700
  ```
668
701
 
669
- * Respect database instance `cursor_sharing` value exact by default
670
-
671
- Oracle enhanced adapter changed `cursor_sharing` parameter value to `force` in Rails 5.1 or lower. However, Oracle enhanced adapter 5.2 supports prepared statements for dictionary queries There is no need to change `cursor_sharing` value to `exact` anymore.
672
-
673
- If you want to keep the old behavior in Rails 5.2, set `cursor_sharing: :force` explicitly in the database.yml.
674
-
675
702
  * Remove `OracleEnhancedAdapter.cache_columns` to use Rails `db:schema:cache:dump`
676
703
 
677
704
  Refer https://github.com/rsim/oracle-enhanced#schema-cache
data/VERSION CHANGED
@@ -1 +1 @@
1
- 5.2.8
1
+ 7.0.3
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- class ActiveRecord::ConnectionAdapters::OracleAdapter < ActiveRecord::ConnectionAdapters::OracleEnhancedAdapter #:nodoc:
3
+ class ActiveRecord::ConnectionAdapters::OracleAdapter < ActiveRecord::ConnectionAdapters::OracleEnhancedAdapter # :nodoc:
4
4
  def adapter_name
5
5
  "Oracle"
6
6
  end
@@ -1,13 +1,13 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ActiveRecord
4
- module ConnectionAdapters #:nodoc:
4
+ module ConnectionAdapters # :nodoc:
5
5
  module OracleEnhanced
6
6
  class Column < ActiveRecord::ConnectionAdapters::Column
7
7
  delegate :virtual, to: :sql_type_metadata, allow_nil: true
8
8
 
9
- def initialize(name, default, sql_type_metadata = nil, null = true, table_name = nil, comment = nil) #:nodoc:
10
- super(name, default, sql_type_metadata, null, table_name, comment: comment)
9
+ def initialize(name, default, sql_type_metadata = nil, null = true, comment: nil) # :nodoc:
10
+ super(name, default, sql_type_metadata, null, comment: comment)
11
11
  end
12
12
 
13
13
  def virtual?