exwiw 1.1.6 → 1.1.7
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/README.md +317 -1018
- data/docs/mongodb.md +4 -0
- data/docs/scope-id-set-join-notes.md +12 -0
- data/lib/exwiw/adapter/mongodb_adapter.rb +12 -0
- data/lib/exwiw/adapter/mysql_adapter.rb +18 -15
- data/lib/exwiw/adapter/postgresql_adapter.rb +26 -16
- data/lib/exwiw/adapter/sqlite_adapter.rb +16 -13
- data/lib/exwiw/adapter.rb +30 -1
- data/lib/exwiw/query_ast.rb +34 -1
- data/lib/exwiw/query_ast_builder.rb +177 -44
- data/lib/exwiw/version.rb +1 -1
- metadata +2 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: a93af3fb75c47b5f8e477716a595c3dd2909e23285c3c5838a965adf640d2db6
|
|
4
|
+
data.tar.gz: c98c7197342539af1faa5fce7c4acc759566cca3b96ea07585cc99e78a297572
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: b7beec90b827baf014bbe16dcb6954374885ee40b2a3be13a17bb354cf51a88611d0dcfbe0273d00f987dc07032f61264d9cd160a9aac1fa5e2608cbceea0ee0
|
|
7
|
+
data.tar.gz: 41c69598a4564af9f6fad2108673101abb0a544f8f721032d9804d860caeaa440d0934b31c14038a988cc39cc98ef7594d5f8530ba7fcee76bdc0b4ab77f62cb
|
data/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
## [Unreleased]
|
|
4
4
|
|
|
5
|
+
## [1.1.7] - 2026-10-01
|
|
6
|
+
|
|
7
|
+
### Added
|
|
8
|
+
|
|
9
|
+
- **A narrowed table with a `belongs_to` to itself also keeps the ancestors of its rows.** A self-reference was ignored on every scoping path, so narrowing a tree table such as `categories` (`parent_id → categories.id`) to the categories a tenant's products point at dropped their parent categories and left `parent_id` dangling in the dump. The SQL adapters now wrap such a table's scope in a `WITH RECURSIVE` walk up every non-polymorphic self-reference, whichever path narrowed it. The ancestors are added regardless of the table's `filter` and scope, so where a tree spans tenants the dump includes the other tenant's ancestors. Tables that `belongs_to` the tree follow the rows including the ancestors, so the ancestors' own child rows are kept too — a table whose join route passes through the tree is narrowed by the route's first table's extraction query instead of being joined along it — and a table the tree points at includes the ancestors' references. A table dumped in full and a table extracted with `batch_scope` are unchanged (the latter with a pre-flight warning); the MongoDB adapter adds no ancestors and warns instead. Tables without a self-reference emit the same SQL as before. Requires MySQL 8.0+ for `WITH RECURSIVE`.
|
|
10
|
+
|
|
5
11
|
## [1.1.6] - 2026-09-29
|
|
6
12
|
|
|
7
13
|
### Added
|