rom-sql 3.7.0 → 3.8.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/CHANGELOG.md CHANGED
@@ -1,62 +1,106 @@
1
- <!--- DO NOT EDIT THIS FILE - IT'S AUTOMATICALLY GENERATED VIA DEVTOOLS --->
1
+ # Changelog
2
2
 
3
- ## 3.7.0 2025-01-08
3
+ All notable changes to this project will be documented in this file.
4
4
 
5
- ### Changed
5
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Break Versioning](https://www.taoensso.com/break-versioning).
6
6
 
7
- - Minimum Ruby version is now 3.1 (@flash-gordon)
7
+ ## [Unreleased]
8
8
 
9
- [Compare v3.6.5...v3.7.0](https://github.com/rom-rb/rom-sql/compare/v3.6.5...v3.7.0)
9
+ ### Added
10
10
 
11
- ## 3.6.5 2024-12-25
11
+ ### Changed
12
12
 
13
+ ### Deprecated
14
+
15
+ ### Removed
13
16
 
14
17
  ### Fixed
15
18
 
16
- - Fix syntax error under Ruby 3.4 (@flash-gordon)
19
+ ### Security
20
+
21
+ [Unreleased]: https://github.com/hanakai-rb/rom-sql/compare/v3.8.0...main
17
22
 
18
- [Compare v3.6.4...v3.6.5](https://github.com/rom-rb/rom-sql/compare/v3.6.4...v3.6.5)
23
+ ## [3.8.0] - 2026-11-27
19
24
 
20
- ## 3.6.4 2024-07-01
25
+ ### Added
26
+
27
+ - Support plain SQL migrations. Write a migration as a `.sql` file in your migrations directory, and use `-- @migrate` comment directives to mark its up and down sections. (@alassek in #440)
28
+
29
+ ```sql
30
+ -- @migrate up
31
+ -- @migrate begin split=semicolon
32
+ CREATE TABLE users (id INTEGER PRIMARY KEY);
33
+ CREATE INDEX users_id_idx ON users (id);
34
+ -- @migrate end
35
+
36
+ -- @migrate down
37
+ -- @migrate begin
38
+ DROP TABLE users
39
+ -- @migrate end
40
+ ```
41
+
42
+ Each direction can have one or more `begin`/`end` sections, which run in order. Use `split=` on a `begin` line to run its body as one statement (the default), split it on semicolons (`split=semicolon`), or split it by line (`split=line`). The down section is optional.
43
+
44
+ ### Changed
21
45
 
46
+ - Require Ruby 3.3 or later.
22
47
 
23
48
  ### Fixed
24
49
 
25
- - Excessive logging when same gateway is shared between multiple containers (@flash-gordon)
26
- - Warning about using color option from active-support log subscriber (@flash-gordon + @bendangelo)
50
+ - Apply read types only once to tuples returned from Create commands. Before, read types were applied twice on all databases except PostgreSQL, which caused errors for read types that could not be applied twice. (@katafrakt in #432)
27
51
 
52
+ [3.8.0]: https://github.com/hanakai-rb/rom-sql/compare/v3.7.0...v3.8.0
28
53
 
29
- [Compare v3.6.3...v3.6.4](https://github.com/rom-rb/rom-sql/compare/v3.6.3...v3.6.4)
54
+ ## [3.7.0] - 2025-01-08
30
55
 
31
- ## 3.6.3 2024-05-06
56
+ ### Changed
32
57
 
58
+ - Minimum Ruby version is now 3.1 (@flash-gordon)
59
+
60
+ [3.7.0]: https://github.com/hanakai-rb/rom-sql/compare/v3.6.5...v3.7.0
61
+
62
+ ## [3.6.5] - 2024-12-25
33
63
 
34
64
  ### Fixed
35
65
 
36
- - Fix using `.filter` with a block for aggregate functions (@flash-gordon)
66
+ - Fix syntax error under Ruby 3.4 (@flash-gordon)
67
+
68
+ [3.6.5]: https://github.com/hanakai-rb/rom-sql/compare/v3.6.4...v3.6.5
69
+
70
+ ## [3.6.4] - 2024-07-01
37
71
 
72
+ ### Fixed
38
73
 
39
- [Compare v3.6.2...v3.6.3](https://github.com/rom-rb/rom-sql/compare/v3.6.2...v3.6.3)
74
+ - Excessive logging when same gateway is shared between multiple containers (@flash-gordon)
75
+ - Warning about using color option from active-support log subscriber (@flash-gordon + @bendangelo)
40
76
 
41
- ## 3.6.2 2024-01-09
77
+ [3.6.4]: https://github.com/hanakai-rb/rom-sql/compare/v3.6.3...v3.6.4
42
78
 
79
+ ## [3.6.3] - 2024-05-06
43
80
 
44
81
  ### Fixed
45
82
 
46
- - Fix Hash.new warning in Ruby 3.3 (@flash-gordon)
83
+ - Fix using `.filter` with a block for aggregate functions (@flash-gordon)
84
+
85
+ [3.6.3]: https://github.com/hanakai-rb/rom-sql/compare/v3.6.2...v3.6.3
86
+
87
+ ## [3.6.2] - 2024-01-09
47
88
 
89
+ ### Fixed
90
+
91
+ - Fix Hash.new warning in Ruby 3.3 (@flash-gordon)
48
92
 
49
- [Compare v3.6.1...v3.6.2](https://github.com/rom-rb/rom-sql/compare/v3.6.1...v3.6.2)
93
+ [3.6.2]: https://github.com/hanakai-rb/rom-sql/compare/v3.6.1...v3.6.2
50
94
 
51
- ## 3.6.1 2022-11-22
95
+ ## [3.6.1] - 2022-11-22
52
96
 
53
97
  ### Fixed
54
98
 
55
99
  - Mapping of cidr types in PostgreSQL to IPAddr values (@flash-gordon)
56
100
 
57
- [Compare v3.6.0...v3.6.1](https://github.com/rom-rb/rom-sql/compare/v3.6.0...v3.6.1)
101
+ [3.6.1]: https://github.com/hanakai-rb/rom-sql/compare/v3.6.0...v3.6.1
58
102
 
59
- ## 3.6.0 2022-11-11
103
+ ## [3.6.0] - 2022-11-11
60
104
 
61
105
  ### Added
62
106
 
@@ -66,63 +110,53 @@
66
110
 
67
111
  - Upgraded to the latest versions of dry-rb dependencies, compatible with rom 5.3 (@flash-gordon)
68
112
 
69
- [Compare v3.5.0...v3.6.0](https://github.com/rom-rb/rom-sql/compare/v3.5.0...v3.6.0)
113
+ [3.6.0]: https://github.com/hanakai-rb/rom-sql/compare/v3.5.0...v3.6.0
70
114
 
71
- ## 3.5.0 2021-03-26
72
-
73
-
74
- ### Fixed
75
-
76
- - Restored the fix for #390 that was lost by an accident in 3.3.3 and 3.4.0 (@solnic)
115
+ ## [3.5.0] - 2021-03-26
77
116
 
78
117
  ### Added
79
118
 
80
119
  - Support for using partial indixes in PG upsert commands (issue #394 fixed via #395) (@smaximov)
81
120
 
82
- [Compare v3.4.0...v3.5.0](https://github.com/rom-rb/rom-sql/compare/v3.4.0...v3.5.0)
121
+ ### Fixed
122
+
123
+ - Restored the fix for #390 that was lost by an accident in 3.3.3 and 3.4.0 (@solnic)
83
124
 
84
- ## 3.4.0 2021-03-19
125
+ [3.5.0]: https://github.com/hanakai-rb/rom-sql/compare/v3.4.0...v3.5.0
85
126
 
127
+ ## [3.4.0] - 2021-03-19
86
128
 
87
129
  ### Added
88
130
 
89
131
  - `Relation#unordered` (@radar)
90
132
 
133
+ [3.4.0]: https://github.com/hanakai-rb/rom-sql/compare/v3.3.3...v3.4.0
91
134
 
92
- [Compare v3.3.3...v3.4.0](https://github.com/rom-rb/rom-sql/compare/v3.3.3...v3.4.0)
93
-
94
- ## 3.3.3 2021-03-05
95
-
135
+ ## [3.3.3] - 2021-03-05
96
136
 
97
137
  ### Added
98
138
 
99
139
  - Support for streaming composite relations (@ianks)
100
140
 
141
+ [3.3.3]: https://github.com/hanakai-rb/rom-sql/compare/v3.3.2...v3.3.3
101
142
 
102
- [Compare v3.3.2...v3.3.3](https://github.com/rom-rb/rom-sql/compare/v3.3.2...v3.3.3)
103
-
104
- ## 3.3.2 2021-01-06
105
-
143
+ ## [3.3.2] - 2021-01-06
106
144
 
107
145
  ### Fixed
108
146
 
109
147
  - Function qualification methods no longer lose options (issue #390 fixed via #391) (@solnic)
110
148
 
149
+ [3.3.2]: https://github.com/hanakai-rb/rom-sql/compare/v3.3.1...v3.3.2
111
150
 
112
- [Compare v3.3.1...v3.3.2](https://github.com/rom-rb/rom-sql/compare/v3.3.1...v3.3.2)
113
-
114
- ## 3.3.1 2020-12-29
115
-
151
+ ## [3.3.1] - 2020-12-29
116
152
 
117
153
  ### Fixed
118
154
 
119
155
  - `:pg_streaming` plugin no longer crashes when there's no sequel_pg and now you need to require the plugin explicitly (@solnic)
120
156
 
157
+ [3.3.1]: https://github.com/hanakai-rb/rom-sql/compare/v3.3.0...v3.3.1
121
158
 
122
- [Compare v3.3.0...v3.3.1](https://github.com/rom-rb/rom-sql/compare/v3.3.0...v3.3.1)
123
-
124
- ## 3.3.0 2020-12-28
125
-
159
+ ## [3.3.0] - 2020-12-28
126
160
 
127
161
  ### Added
128
162
 
@@ -142,21 +176,17 @@ posts.full_text_search([:title], 'tutorials', language: 'english')
142
176
  - `Relation#join` no longer crashes when aliased relation is used with a block (issue #369) (@abrthel)
143
177
  - Attributes aliases are properly handled when constructing queries with SQL functions (issue #370 fixed via #373) (@abrthel)
144
178
 
179
+ [3.3.0]: https://github.com/hanakai-rb/rom-sql/compare/v3.2.0...v3.3.0
145
180
 
146
- [Compare v3.2.0...v3.3.0](https://github.com/rom-rb/rom-sql/compare/v3.2.0...v3.3.0)
147
-
148
- ## 3.2.0 2020-01-11
149
-
181
+ ## [3.2.0] - 2020-01-11
150
182
 
151
183
  ### Fixed
152
184
 
153
185
  - Keyword warnings on Ruby 2.7 (@flash-gordon)
154
186
 
187
+ [3.2.0]: https://github.com/hanakai-rb/rom-sql/compare/v3.1.0...v3.2.0
155
188
 
156
- [Compare v3.1.0...v3.2.0](https://github.com/rom-rb/rom-sql/compare/v3.1.0...v3.2.0)
157
-
158
- ## 3.1.0 2019-12-16
159
-
189
+ ## [3.1.0] - 2019-12-16
160
190
 
161
191
  ### Added
162
192
 
@@ -179,21 +209,17 @@ posts.full_text_search([:title], 'tutorials', language: 'english')
179
209
  - Properly qualify relations when in `Relation#union` (@ianks)
180
210
  - `Relation#query` no longer removes order in the relation (@DNNX)
181
211
 
212
+ [3.1.0]: https://github.com/hanakai-rb/rom-sql/compare/v3.0.1...v3.1.0
182
213
 
183
- [Compare v3.0.1...v3.1.0](https://github.com/rom-rb/rom-sql/compare/v3.0.1...v3.1.0)
184
-
185
- ## 3.0.1 2019-05-05
186
-
214
+ ## [3.0.1] - 2019-05-05
187
215
 
188
216
  ### Fixed
189
217
 
190
218
  - Using joins with a relation object as the target and a block-based conditions produces correct query now (issue #331) (solnic)
191
219
 
220
+ [3.0.1]: https://github.com/hanakai-rb/rom-sql/compare/v3.0.0...v3.0.1
192
221
 
193
- [Compare v3.0.0...v3.0.1](https://github.com/rom-rb/rom-sql/compare/v3.0.0...v3.0.1)
194
-
195
- ## 3.0.0 2019-04-24
196
-
222
+ ## [3.0.0] - 2019-04-24
197
223
 
198
224
  ### Added
199
225
 
@@ -232,29 +258,28 @@ posts.full_text_search([:title], 'tutorials', language: 'english')
232
258
  ```
233
259
  - `Relation#unfiltered` returns an unrestricted relation (removes restrictions from `WHERE` and `HAVING`) (flash-gordon)
234
260
  - Support for `WITHIN GROUP` in the function DSL has been enhanced with block syntax (flash-gordon)
235
- - ```ruby
236
- - # previously available version
237
- - households.project { float::percentile_cont(0.5).within_group(income).as(:percentile) }
238
- - # using the new syntax
239
- - households.project { float::percentile_cont(0.5).within_group { income }.as(:percentile) }
240
- - ```
261
+ ```ruby
262
+ # previously available version
263
+ households.project { float::percentile_cont(0.5).within_group(income).as(:percentile) }
264
+ # using the new syntax
265
+ households.project { float::percentile_cont(0.5).within_group { income }.as(:percentile) }
266
+ ```
241
267
  - Support for migrator options ie `ROM::Configuration.new(:sql, migrator: { path: "my_migrations" })` (rawburt)
242
268
  - `Relation#pluck` works with multiple args too (timriley)
243
269
 
244
- ### Fixed
245
-
246
- - Using `Relation#inner_join` with has-many-through produces correct query (issue #279) (doriantaylor + solnic)
247
- - Aliased attributes are handled correctly in `Relation#where` (waiting-for-dev)
248
-
249
270
  ### Changed
250
271
 
251
272
  - [BREAKING] Updated to work with `dry-types 1.0.0` (flash-gordon)
252
273
  - [BREAKING] `Types::Int` is now `Types::Integer` (GustavoCaso)
253
274
 
254
- [Compare v2.5.0...v3.0.0](https://github.com/rom-rb/rom-sql/compare/v2.5.0...v3.0.0)
275
+ ### Fixed
276
+
277
+ - Using `Relation#inner_join` with has-many-through produces correct query (issue #279) (doriantaylor + solnic)
278
+ - Aliased attributes are handled correctly in `Relation#where` (waiting-for-dev)
255
279
 
256
- ## 2.5.0 2018-06-08
280
+ [3.0.0]: https://github.com/hanakai-rb/rom-sql/compare/v2.5.0...v3.0.0
257
281
 
282
+ ## [2.5.0] - 2018-06-08
258
283
 
259
284
  ### Added
260
285
 
@@ -267,22 +292,18 @@ posts.full_text_search([:title], 'tutorials', language: 'english')
267
292
  users.select_append(tasks_count.as(:tasks_count))
268
293
  ```
269
294
 
295
+ [2.5.0]: https://github.com/hanakai-rb/rom-sql/compare/v2.4.0...v2.5.0
270
296
 
271
- [Compare v2.4.0...v2.5.0](https://github.com/rom-rb/rom-sql/compare/v2.4.0...v2.5.0)
272
-
273
- ## 2.4.0 2018-02-18
274
-
297
+ ## [2.4.0] - 2018-02-18
275
298
 
276
299
  ### Added
277
300
 
278
301
  - Support for functions with `Any` return type (GustavoCaso)
279
302
  - New `Relation#as_hash` method (GustavoCaso)
280
303
 
304
+ [2.4.0]: https://github.com/hanakai-rb/rom-sql/compare/v2.3.0...v2.4.0
281
305
 
282
- [Compare v2.3.0...v2.4.0](https://github.com/rom-rb/rom-sql/compare/v2.3.0...v2.4.0)
283
-
284
- ## 2.3.0 2017-11-17
285
-
306
+ ## [2.3.0] - 2017-11-17
286
307
 
287
308
  ### Added
288
309
 
@@ -294,22 +315,18 @@ posts.full_text_search([:title], 'tutorials', language: 'english')
294
315
  - Aliased attributes are handled correctly in PG's commands (cflipse)
295
316
  - Command extensions are properly applied in multi-adapter setups (solnic)
296
317
 
318
+ [2.3.0]: https://github.com/hanakai-rb/rom-sql/compare/v2.2.1...v2.3.0
297
319
 
298
- [Compare v2.2.1...v2.3.0](https://github.com/rom-rb/rom-sql/compare/v2.2.1...v2.3.0)
299
-
300
- ## 2.2.1 2017-11-10
301
-
320
+ ## [2.2.1] - 2017-11-10
302
321
 
303
322
  ### Fixed
304
323
 
305
324
  - Instrumentation works with all db interactions (not just queries that materialize relations) (solnic)
306
325
  - Typo in `MissingEnv` exception message (romatr)
307
326
 
327
+ [2.2.1]: https://github.com/hanakai-rb/rom-sql/compare/v2.2.0...v2.2.1
308
328
 
309
- [Compare v2.2.0...v2.2.1](https://github.com/rom-rb/rom-sql/compare/v2.2.0...v2.2.1)
310
-
311
- ## 2.2.0 2017-11-02
312
-
329
+ ## [2.2.0] - 2017-11-02
313
330
 
314
331
  ### Added
315
332
 
@@ -322,11 +339,9 @@ posts.full_text_search([:title], 'tutorials', language: 'english')
322
339
  - Custom schema is used correctly in command results (solnic)
323
340
  - Schemas no longer finalize PKs (this is done in core schema already) (solnic)
324
341
 
342
+ [2.2.0]: https://github.com/hanakai-rb/rom-sql/compare/v2.1.0...v2.2.0
325
343
 
326
- [Compare v2.1.0...v2.2.0](https://github.com/rom-rb/rom-sql/compare/v2.1.0...v2.2.0)
327
-
328
- ## 2.1.0 2017-10-23
329
-
344
+ ## [2.1.0] - 2017-10-23
330
345
 
331
346
  ### Added
332
347
 
@@ -340,11 +355,9 @@ posts.full_text_search([:title], 'tutorials', language: 'english')
340
355
  - Schema inference works with primary keys that have custom types (ie an enum PK column) (v-kolesnikov)
341
356
  - Ruby warnings are gone (solnic)
342
357
 
358
+ [2.1.0]: https://github.com/hanakai-rb/rom-sql/compare/v2.0.0...v2.1.0
343
359
 
344
- [Compare v2.0.0...v2.1.0](https://github.com/rom-rb/rom-sql/compare/v2.0.0...v2.1.0)
345
-
346
- ## 2.0.0 2017-10-18
347
-
360
+ ## [2.0.0] - 2017-10-18
348
361
 
349
362
  ### Added
350
363
 
@@ -411,13 +424,6 @@ posts.full_text_search([:title], 'tutorials', language: 'english')
411
424
  users.where { lower(name).not('John') }
412
425
  ```
413
426
 
414
- ### Fixed
415
-
416
- - Self-ref associations work correctly with custom FKs (solnic)
417
- - Aliased associations with custom FKs work correctly (solnic)
418
- - Defining a custom dataset block no longer prevents default views like `by_pk` to be defined (solnic)
419
- - `Relation#group` uses canonical schema now (solnic)
420
-
421
427
  ### Changed
422
428
 
423
429
  - [BREAKING] based on rom 4.0 now (flash-gordon + solnic)
@@ -431,10 +437,32 @@ posts.full_text_search([:title], 'tutorials', language: 'english')
431
437
  - Schemas are qualified by default (solnic)
432
438
  - `PG::JSON`, `PG::JSONB`, and `PG::Array` now all have read types so that they return plain Hash/Array values instead of Sequel's wrappers (flash-gordon)
433
439
 
434
- [Compare v1.3.3...v2.0.0](https://github.com/rom-rb/rom-sql/compare/v1.3.3...v2.0.0)
440
+ ### Fixed
441
+
442
+ - Self-ref associations work correctly with custom FKs (solnic)
443
+ - Aliased associations with custom FKs work correctly (solnic)
444
+ - Defining a custom dataset block no longer prevents default views like `by_pk` to be defined (solnic)
445
+ - `Relation#group` uses canonical schema now (solnic)
446
+
447
+ [2.0.0]: https://github.com/hanakai-rb/rom-sql/compare/v1.3.3...v2.0.0
448
+
449
+ ## [1.3.5] - 2017-10-12
450
+
451
+ ### Changed
452
+
453
+ - Added compatibility with `dry-types` 0.11 (flash-gordon)
435
454
 
436
- ## 1.3.3 2017-05-30
455
+ [1.3.5]: https://github.com/hanakai-rb/rom-sql/compare/v1.3.4...v1.3.5
437
456
 
457
+ ## [1.3.4] - 2017-09-12
458
+
459
+ ### Fixed
460
+
461
+ - A warning caused by using `EMPTY_BRACKET` from Sequel (flash-gordon)
462
+
463
+ [1.3.4]: https://github.com/hanakai-rb/rom-sql/compare/v1.3.3...v1.3.4
464
+
465
+ ## [1.3.3] - 2017-05-30
438
466
 
439
467
  ### Added
440
468
 
@@ -456,11 +484,9 @@ posts.full_text_search([:title], 'tutorials', language: 'english')
456
484
 
457
485
  - Fixed a regression introduced in v1.3.2 caused by doing way more work processing the default dataset (flash-gordon)
458
486
 
487
+ [1.3.3]: https://github.com/hanakai-rb/rom-sql/compare/v1.3.2...v1.3.3
459
488
 
460
- [Compare v1.3.2...v1.3.3](https://github.com/rom-rb/rom-sql/compare/v1.3.2...v1.3.3)
461
-
462
- ## 1.3.2 2017-05-13
463
-
489
+ ## [1.3.2] - 2017-05-13
464
490
 
465
491
  ### Added
466
492
 
@@ -472,20 +498,17 @@ posts.full_text_search([:title], 'tutorials', language: 'english')
472
498
 
473
499
  - A bunch of warnings from Sequel 4.46
474
500
 
501
+ [1.3.2]: https://github.com/hanakai-rb/rom-sql/compare/v1.3.1...v1.3.2
475
502
 
476
- [Compare v1.3.1...v1.3.2](https://github.com/rom-rb/rom-sql/compare/v1.3.1...v1.3.2)
477
-
478
- ## 1.3.1 2017-05-05
479
-
503
+ ## [1.3.1] - 2017-05-05
480
504
 
481
505
  ### Changed
482
506
 
483
507
  - [internal] Compatibility with `dry-core` v0.3.0 (flash-gordon)
484
508
 
485
- [Compare v1.3.0...v1.3.1](https://github.com/rom-rb/rom-sql/compare/v1.3.0...v1.3.1)
486
-
487
- ## 1.3.0 2017-05-02
509
+ [1.3.1]: https://github.com/hanakai-rb/rom-sql/compare/v1.3.0...v1.3.1
488
510
 
511
+ ## [1.3.0] - 2017-05-02
489
512
 
490
513
  ### Added
491
514
 
@@ -495,13 +518,6 @@ posts.full_text_search([:title], 'tutorials', language: 'english')
495
518
  - Add `ROM::SQL::Attribute#!` for negated attribute's sql expressions (solnic)
496
519
  - Inferrer gets limit constraints for string data types and stores them in type's meta (v-kolesnikov)
497
520
 
498
- ### Fixed
499
-
500
- - Fixed usage of PostgreSQL's commands with a composite relation (flash-gordon)
501
- - Translation of `true/false/nil` equality checks to `is/is not` SQL statements in `ROM::SQL::Attribute#is` (AMHOL)
502
- - `associates` command plugin coerces parent collections to hashes correctly (aarek+solnic)
503
- - `by_pk` works correctly even when PK is not projected (solnic)
504
-
505
521
  ### Changed
506
522
 
507
523
  - Global private interface `SQL::Gateway.instance` has been deprecated. Now if you run migrations
@@ -515,29 +531,32 @@ posts.full_text_search([:title], 'tutorials', language: 'english')
515
531
  end
516
532
  ```
517
533
 
518
- [Compare v1.2.2...v1.3.0](https://github.com/rom-rb/rom-sql/compare/v1.2.2...v1.3.0)
534
+ ### Fixed
519
535
 
520
- ## 1.2.2 2017-03-25
536
+ - Fixed usage of PostgreSQL's commands with a composite relation (flash-gordon)
537
+ - Translation of `true/false/nil` equality checks to `is/is not` SQL statements in `ROM::SQL::Attribute#is` (AMHOL)
538
+ - `associates` command plugin coerces parent collections to hashes correctly (aarek+solnic)
539
+ - `by_pk` works correctly even when PK is not projected (solnic)
521
540
 
541
+ [1.3.0]: https://github.com/hanakai-rb/rom-sql/compare/v1.2.2...v1.3.0
542
+
543
+ ## [1.2.2] - 2017-03-25
522
544
 
523
545
  ### Changed
524
546
 
525
547
  - Updated `dry-initializer` (flash-gordon)
526
548
 
527
- [Compare v1.2.1...v1.2.2](https://github.com/rom-rb/rom-sql/compare/v1.2.1...v1.2.2)
528
-
529
- ## 1.2.1 2017-03-09
549
+ [1.2.2]: https://github.com/hanakai-rb/rom-sql/compare/v1.2.1...v1.2.2
530
550
 
551
+ ## [1.2.1] - 2017-03-09
531
552
 
532
553
  ### Fixed
533
554
 
534
555
  - Allow for joining by a `RelationProxy` instance from `rom-repository` (davydovanton)
535
556
 
557
+ [1.2.1]: https://github.com/hanakai-rb/rom-sql/compare/v1.2.0...v1.2.1
536
558
 
537
- [Compare v1.2.0...v1.2.1](https://github.com/rom-rb/rom-sql/compare/v1.2.0...v1.2.1)
538
-
539
- ## 1.2.0 2017-03-07
540
-
559
+ ## [1.2.0] - 2017-03-07
541
560
 
542
561
  ### Added
543
562
 
@@ -545,31 +564,25 @@ posts.full_text_search([:title], 'tutorials', language: 'english')
545
564
  - Support for passing parent tuple(s) as `parent` option in `Command#with_association` (solnic)
546
565
  - Support for join using assocation name (flash-gordon)
547
566
 
567
+ [1.2.0]: https://github.com/hanakai-rb/rom-sql/compare/v1.1.2...v1.2.0
548
568
 
549
- [Compare v1.1.2...v1.2.0](https://github.com/rom-rb/rom-sql/compare/v1.1.2...v1.2.0)
550
-
551
- ## 1.1.2 2017-03-02
552
-
569
+ ## [1.1.2] - 2017-03-02
553
570
 
554
571
  ### Fixed
555
572
 
556
573
  - Fix grouping by a function in the block DSL (flash-gordon)
557
574
 
575
+ [1.1.2]: https://github.com/hanakai-rb/rom-sql/compare/v1.1.1...v1.1.2
558
576
 
559
- [Compare v1.1.1...v1.1.2](https://github.com/rom-rb/rom-sql/compare/v1.1.1...v1.1.2)
560
-
561
- ## 1.1.1 2017-03-01
562
-
577
+ ## [1.1.1] - 2017-03-01
563
578
 
564
579
  ### Fixed
565
580
 
566
581
  - Restriction conditions with an array as a value are handled correctly by attribute types (solnic)
567
582
 
583
+ [1.1.1]: https://github.com/hanakai-rb/rom-sql/compare/v1.1.0...v1.1.1
568
584
 
569
- [Compare v1.1.0...v1.1.1](https://github.com/rom-rb/rom-sql/compare/v1.1.0...v1.1.1)
570
-
571
- ## 1.1.0 2017-03-01
572
-
585
+ ## [1.1.0] - 2017-03-01
573
586
 
574
587
  ### Added
575
588
 
@@ -583,34 +596,29 @@ posts.full_text_search([:title], 'tutorials', language: 'english')
583
596
  - Missing `group` method was added to legacy `SequelAPI` module (solnic)
584
597
  - Associations properly maintain `order` if it was set (solnic)
585
598
 
599
+ [1.1.0]: https://github.com/hanakai-rb/rom-sql/compare/v1.0.3...v1.1.0
586
600
 
587
- [Compare v1.0.3...v1.1.0](https://github.com/rom-rb/rom-sql/compare/v1.0.3...v1.1.0)
601
+ ## [1.0.3] - 2017-02-23
588
602
 
589
- ## 1.0.3 2017-02-23
603
+ ### Changed
590
604
 
605
+ - `AutoCombine#preload` uses better restriction for `ManyToOne` association which greatly speeds up loading bigger amounts of data (solnic + flash-gordon)
591
606
 
592
607
  ### Fixed
593
608
 
594
609
  - Fix the usage of timestamp in command chains (cflipse)
595
610
 
596
- ### Changed
597
-
598
- - `AutoCombine#preload` uses better restriction for `ManyToOne` association which greatly speeds up loading bigger amounts of data (solnic + flash-gordon)
599
-
600
- [Compare v1.0.2...v1.0.3](https://github.com/rom-rb/rom-sql/compare/v1.0.2...v1.0.3)
601
-
602
- ## 1.0.2 2017-02-16
611
+ [1.0.3]: https://github.com/hanakai-rb/rom-sql/compare/v1.0.2...v1.0.3
603
612
 
613
+ ## [1.0.2] - 2017-02-16
604
614
 
605
615
  ### Added
606
616
 
607
617
  - Support for selecting literal strings via `` select { `'foo'`.as(:bar) } `` (solnic)
608
618
 
619
+ [1.0.2]: https://github.com/hanakai-rb/rom-sql/compare/v1.0.1...v1.0.2
609
620
 
610
- [Compare v1.0.1...v1.0.2](https://github.com/rom-rb/rom-sql/compare/v1.0.1...v1.0.2)
611
-
612
- ## 1.0.1 2017-02-09
613
-
621
+ ## [1.0.1] - 2017-02-09
614
622
 
615
623
  ### Added
616
624
 
@@ -623,10 +631,9 @@ posts.full_text_search([:title], 'tutorials', language: 'english')
623
631
 
624
632
  - Missing primary key now leads to a more meaningful error (flash-gordon)
625
633
 
634
+ [1.0.1]: https://github.com/hanakai-rb/rom-sql/compare/v1.0.0...v1.0.1
626
635
 
627
- [Compare v1.0.0...v1.0.1](https://github.com/rom-rb/rom-sql/compare/v1.0.0...v1.0.1)
628
-
629
- ## 1.0.0 2017-01-29
636
+ ## [1.0.0] - 2017-01-29
630
637
 
631
638
  Please refer to [the upgrading guide](https://github.com/rom-rb/rom-sql/wiki/Upgrading-from-0.9.x-to-1.0.0) if you're moving from 0.9.x to 1.0.0.
632
639
 
@@ -664,21 +671,18 @@ Please refer to [the upgrading guide](https://github.com/rom-rb/rom-sql/wiki/Upg
664
671
  - [internal] `select`, `select_append`, `project`, `inner_join` and `left_join` use schemas internally (solnic)
665
672
  - [internal] Deprecation and constants are now based on dry-core (flash-gordon)
666
673
 
667
- [Compare v0.9.1...v1.0.0](https://github.com/rom-rb/rom-sql/compare/v0.9.1...v1.0.0)
668
-
669
- ## 0.9.1 2016-12-23
674
+ [1.0.0]: https://github.com/hanakai-rb/rom-sql/compare/v0.9.1...v1.0.0
670
675
 
676
+ ## [0.9.1] - 2016-12-23
671
677
 
672
678
  ### Added
673
679
 
674
680
  - Support for PG enums in schema inferrer (flash-gordon)
675
681
  - `ROM::SQL::Relation#read` method which accepts an SQL string and returns a new relation (solnic)
676
682
 
683
+ [0.9.1]: https://github.com/hanakai-rb/rom-sql/compare/v0.9.0...v0.9.1
677
684
 
678
- [Compare v0.9.0...v0.9.1](https://github.com/rom-rb/rom-sql/compare/v0.9.0...v0.9.1)
679
-
680
- ## 0.9.0 2016-11-08
681
-
685
+ ## [0.9.0] - 2016-11-08
682
686
 
683
687
  ### Added
684
688
 
@@ -688,10 +692,6 @@ Please refer to [the upgrading guide](https://github.com/rom-rb/rom-sql/wiki/Upg
688
692
  - Automatically infer PG arrays and JSON(B) types (jodosha + flash-gordon)
689
693
  - Support for `Relation#having` (cflipse)
690
694
 
691
- ### Fixed
692
-
693
- - Floats are inferred by schemas (cflipse)
694
-
695
695
  ### Changed
696
696
 
697
697
  - Inferred types in schemas **are no longer strict** (flash-gordon)
@@ -699,10 +699,13 @@ Please refer to [the upgrading guide](https://github.com/rom-rb/rom-sql/wiki/Upg
699
699
  - Make `OneToOne` inherit from `OneToMany` (beauby)
700
700
  - Default dataset will use column names from schema if it's available (solnic)
701
701
 
702
- [Compare v0.8.0...v0.9.0](https://github.com/rom-rb/rom-sql/compare/v0.8.0...v0.9.0)
702
+ ### Fixed
703
703
 
704
- ## 0.8.0 2016-07-27
704
+ - Floats are inferred by schemas (cflipse)
705
+
706
+ [0.9.0]: https://github.com/hanakai-rb/rom-sql/compare/v0.8.0...v0.9.0
705
707
 
708
+ ## [0.8.0] - 2016-07-27
706
709
 
707
710
  ### Added
708
711
 
@@ -718,20 +721,19 @@ Please refer to [the upgrading guide](https://github.com/rom-rb/rom-sql/wiki/Upg
718
721
  - Support for arbitrary dataset and FK names in schemas (flash-gordon)
719
722
  - Support for native upserts in PostgreSQL >= 9.5 via `Commands::Postgres::Upsert` (gotar + flash-gordon)
720
723
 
721
- ### Fixed
722
-
723
- - `Create` command properly materialize result when `:one` is set (AMHOL)
724
-
725
724
  ### Changed
726
725
 
727
726
  - `Create` and `Update` commands have `:schema` plugin enabled by default which sets input handler based on schema definition automatically (solnic)
728
727
  - `associates` command plugin uses schema associations now (solnic)
729
728
  - Dropped MRI 2.0.x support
730
729
 
731
- [Compare v0.7.0...v0.8.0](https://github.com/rom-rb/rom-sql/compare/v0.7.0...v0.8.0)
730
+ ### Fixed
731
+
732
+ - `Create` command properly materialize result when `:one` is set (AMHOL)
732
733
 
733
- ## 0.7.0 2016-01-06
734
+ [0.8.0]: https://github.com/hanakai-rb/rom-sql/compare/v0.7.0...v0.8.0
734
735
 
736
+ ## [0.7.0] - 2016-01-06
735
737
 
736
738
  ### Added
737
739
 
@@ -756,44 +758,39 @@ Please refer to [the upgrading guide](https://github.com/rom-rb/rom-sql/wiki/Upg
756
758
  - `ROM::SQL.gateway` renamed to `ROM::SQL::Gateway.instance` for migrations (endash)
757
759
  - Association macros are now an optional plugin (solnic)
758
760
 
759
- [Compare v0.6.1...v0.7.0](https://github.com/rom-rb/rom-sql/compare/v0.6.1...v0.7.0)
760
-
761
- ## 0.6.1 2015-09-23
761
+ [0.7.0]: https://github.com/hanakai-rb/rom-sql/compare/v0.6.1...v0.7.0
762
762
 
763
+ ## [0.6.1] - 2015-09-23
763
764
 
764
765
  ### Added
765
766
 
766
767
  - `Gateway` accepts `:extensions` as an option (c0)
767
768
 
769
+ [0.6.1]: https://github.com/hanakai-rb/rom-sql/compare/v0.6.0...v0.6.1
768
770
 
769
- [Compare v0.6.0...v0.6.1](https://github.com/rom-rb/rom-sql/compare/v0.6.0...v0.6.1)
770
-
771
- ## 0.6.0 2015-08-19
771
+ ## [0.6.0] - 2015-08-19
772
772
 
773
773
  Internal updates to fix deprecation warnings from ROM 0.9.0.
774
774
 
775
+ [0.6.0]: https://github.com/hanakai-rb/rom-sql/compare/v0.5.3...v0.6.0
775
776
 
776
- [Compare v0.5.3...v0.6.0](https://github.com/rom-rb/rom-sql/compare/v0.5.3...v0.6.0)
777
-
778
- ## 0.5.3 2015-07-23
779
-
777
+ ## [0.5.3] - 2015-07-23
780
778
 
781
779
  ### Added
782
780
 
783
781
  - `Relation#multi_insert` (draxxxeus)
784
782
 
785
- ### Fixed
786
-
787
- - Relation name and join key fixes for `many_to_one` macro (jamesmoriarty)
788
-
789
783
  ### Changed
790
784
 
791
785
  - Command that receives many tuples will use `multi_insert` now (draxxxeus)
792
786
 
793
- [Compare v0.5.2...v0.5.3](https://github.com/rom-rb/rom-sql/compare/v0.5.2...v0.5.3)
787
+ ### Fixed
788
+
789
+ - Relation name and join key fixes for `many_to_one` macro (jamesmoriarty)
794
790
 
795
- ## 0.5.2 2015-06-22
791
+ [0.5.3]: https://github.com/hanakai-rb/rom-sql/compare/v0.5.2...v0.5.3
796
792
 
793
+ ## [0.5.2] - 2015-06-22
797
794
 
798
795
  ### Added
799
796
 
@@ -804,23 +801,21 @@ Internal updates to fix deprecation warnings from ROM 0.9.0.
804
801
  - Migration tasks no longer require entire ROM env (solnic)
805
802
  - `Repository` => `Gateway` rename for ROM 0.8.0 compatibility (solnic)
806
803
 
807
- [Compare v0.5.1...v0.5.2](https://github.com/rom-rb/rom-sql/compare/v0.5.1...v0.5.2)
808
-
809
- ## 0.5.1 2015-05-25
810
-
804
+ [0.5.2]: https://github.com/hanakai-rb/rom-sql/compare/v0.5.1...v0.5.2
811
805
 
812
- ### Fixed
813
-
814
- - Wrap errors when calling commands with `[]`-syntax (kwando)
806
+ ## [0.5.1] - 2015-05-25
815
807
 
816
808
  ### Changed
817
809
 
818
810
  - Relations won't be finalized when table(s) is/are missing (solnic)
819
811
 
820
- [Compare v0.5.0...v0.5.1](https://github.com/rom-rb/rom-sql/compare/v0.5.0...v0.5.1)
812
+ ### Fixed
821
813
 
822
- ## 0.5.0 2015-05-22
814
+ - Wrap errors when calling commands with `[]`-syntax (kwando)
815
+
816
+ [0.5.1]: https://github.com/hanakai-rb/rom-sql/compare/v0.5.0...v0.5.1
823
817
 
818
+ ## [0.5.0] - 2015-05-22
824
819
 
825
820
  ### Added
826
821
 
@@ -839,20 +834,17 @@ Internal updates to fix deprecation warnings from ROM 0.9.0.
839
834
  - `Commands::Update#set` has been deprecated (solnic)
840
835
  - `Commands::Update#to` has been deprecated (solnic)
841
836
 
842
- [Compare v0.4.3...v0.5.0](https://github.com/rom-rb/rom-sql/compare/v0.4.3...v0.5.0)
843
-
844
- ## 0.4.3 2015-05-17
837
+ [0.5.0]: https://github.com/hanakai-rb/rom-sql/compare/v0.4.3...v0.5.0
845
838
 
839
+ ## [0.4.3] - 2015-05-17
846
840
 
847
841
  ### Fixed
848
842
 
849
843
  - `transaction` doesn't swallow errors now other than CommandError (solnic)
850
844
 
845
+ [0.4.3]: https://github.com/hanakai-rb/rom-sql/compare/v0.4.2...v0.4.3
851
846
 
852
- [Compare v0.4.2...v0.4.3](https://github.com/rom-rb/rom-sql/compare/v0.4.2...v0.4.3)
853
-
854
- ## 0.4.2 2015-05-17
855
-
847
+ ## [0.4.2] - 2015-05-17
856
848
 
857
849
  ### Added
858
850
 
@@ -860,31 +852,28 @@ Internal updates to fix deprecation warnings from ROM 0.9.0.
860
852
  - Support for `:conditions` option in association definition (solnic)
861
853
  - Better error message when accessing undefined associations (pdswan)
862
854
 
855
+ ### Changed
856
+
857
+ - `transaction` returns command failure objects when there was a rollback (solnic)
858
+
863
859
  ### Fixed
864
860
 
865
861
  - Correct `ROM::SQL::Plugin::Pagination::Pager#total_pages` when total is not
866
862
  evenly divisible by page size (larribas)
867
863
  - `association_join` behaves correctly when dataset is different than register_as (nepalez)
868
864
 
869
- ### Changed
870
-
871
- - `transaction` returns command failure objects when there was a rollback (solnic)
872
-
873
- [Compare v0.4.1...v0.4.2](https://github.com/rom-rb/rom-sql/compare/v0.4.1...v0.4.2)
874
-
875
- ## 0.4.1 2015-04-04
865
+ [0.4.2]: https://github.com/hanakai-rb/rom-sql/compare/v0.4.1...v0.4.2
876
866
 
867
+ ## [0.4.1] - 2015-04-04
877
868
 
878
869
  ### Added
879
870
 
880
871
  - Database error handling for update and delete commands (kwando + solnic)
881
872
  - Migration interface as a repository plugin (gotar + solnic)
882
873
 
874
+ [0.4.1]: https://github.com/hanakai-rb/rom-sql/compare/v0.4.0...v0.4.1
883
875
 
884
- [Compare v0.4.0...v0.4.1](https://github.com/rom-rb/rom-sql/compare/v0.4.0...v0.4.1)
885
-
886
- ## 0.4.0 2015-03-22
887
-
876
+ ## [0.4.0] - 2015-03-22
888
877
 
889
878
  ### Added
890
879
 
@@ -895,49 +884,43 @@ Internal updates to fix deprecation warnings from ROM 0.9.0.
895
884
  - Pagination plugin (solnic)
896
885
  - Allow reuse of established Sequel connections (splattael)
897
886
 
898
- ### Fixed
899
-
900
- - Indentation in Rails logger (morgoth)
901
-
902
887
  ### Changed
903
888
 
904
889
  - Use ROM's own inflector which uses either ActiveSupport or Inflecto backends (mjtko)
905
890
 
906
- [Compare v0.3.2...v0.4.0](https://github.com/rom-rb/rom-sql/compare/v0.3.2...v0.4.0)
891
+ ### Fixed
892
+
893
+ - Indentation in Rails logger (morgoth)
907
894
 
908
- ## 0.3.2 2015-01-01
895
+ [0.4.0]: https://github.com/hanakai-rb/rom-sql/compare/v0.3.2...v0.4.0
909
896
 
897
+ ## [0.3.2] - 2015-01-01
910
898
 
911
899
  ### Fixed
912
900
 
913
901
  - Checking tuple count in commands (solnic)
914
902
 
903
+ [0.3.2]: https://github.com/hanakai-rb/rom-sql/compare/v0.3.1...v0.3.2
915
904
 
916
- [Compare v0.3.1...v0.3.2](https://github.com/rom-rb/rom-sql/compare/v0.3.1...v0.3.2)
917
-
918
- ## 0.3.1 2014-12-31
919
-
905
+ ## [0.3.1] - 2014-12-31
920
906
 
921
907
  ### Added
922
908
 
923
909
  - `Adapter#disconnect` (solnic)
924
910
  - Support for extra connection options (solnic)
925
911
 
912
+ [0.3.1]: https://github.com/hanakai-rb/rom-sql/compare/v0.3.0...v0.3.1
926
913
 
927
- [Compare v0.3.0...v0.3.1](https://github.com/rom-rb/rom-sql/compare/v0.3.0...v0.3.1)
928
-
929
- ## 0.3.0 2014-12-19
930
-
914
+ ## [0.3.0] - 2014-12-19
931
915
 
932
916
  ### Changed
933
917
 
934
918
  - `association_join` now uses Sequel's `graph` interface which qualifies columns automatically (solnic)
935
919
  - Delete command returns deleted tuples (solnic)
936
920
 
937
- [Compare v0.2.0...v0.3.0](https://github.com/rom-rb/rom-sql/compare/v0.2.0...v0.3.0)
938
-
939
- ## 0.2.0 2014-12-06
921
+ [0.3.0]: https://github.com/hanakai-rb/rom-sql/compare/v0.2.0...v0.3.0
940
922
 
923
+ ## [0.2.0] - 2014-12-06
941
924
 
942
925
  ### Added
943
926
 
@@ -945,22 +928,22 @@ Internal updates to fix deprecation warnings from ROM 0.9.0.
945
928
  - Support for ActiveSupport::Notifications with a log subscriber (solnic)
946
929
  - New `ROM::SQL::Adapter#dataset?(name)` checking if a given table exists (solnic)
947
930
 
931
+ [0.2.0]: https://github.com/hanakai-rb/rom-sql/compare/v0.1.1...v0.2.0
948
932
 
949
- [Compare v0.1.1...v0.2.0](https://github.com/rom-rb/rom-sql/compare/v0.1.1...v0.2.0)
933
+ ## [0.1.1] - 2014-11-24
950
934
 
951
- ## 0.1.1 2014-11-24
935
+ ### Changed
952
936
 
937
+ - minor refactor in adapter (solnic)
953
938
 
954
939
  ### Fixed
955
940
 
956
941
  - Equalizer in header (solnic)
957
942
 
958
- ### Changed
959
-
960
- - minor refactor in adapter (solnic)
961
-
962
- [Compare v0.1.0...v0.1.1](https://github.com/rom-rb/rom-sql/compare/v0.1.0...v0.1.1)
943
+ [0.1.1]: https://github.com/hanakai-rb/rom-sql/compare/v0.1.0...v0.1.1
963
944
 
964
- ## 0.1.0 2014-11-24
945
+ ## [0.1.0] - 2014-11-24
965
946
 
966
947
  First release powered by Sequel
948
+
949
+ [0.1.0]: https://github.com/hanakai-rb/rom-sql/tree/v0.1.0