Commit graph

273 commits

Author SHA1 Message Date
Zach Daniel
38eec0ba86 docs: reformat docs and revisit certain guides
improvement: support `mix ash.rollback` with interactive rollback
2024-04-09 20:21:04 -04:00
Zach Daniel
cfaf1f8201 test: fix test application in CI
fix: use proper sql implementation in `default_bindings`
2024-04-06 10:12:31 -04:00
Zach Daniel
eb08fed28b improvement: fixes for 3.0 changes and AshSql changes 2024-04-01 13:58:44 -04:00
Zach Daniel
efcc1a651b improvement: move many internals out to AshSql package 2024-03-31 22:38:12 -04:00
Zach Daniel
3647fc42ee improvement: add default implementation for pg_version, and rename to min_pg_version 2024-03-27 19:20:49 -04:00
Zach Daniel
37cc01957d
improvement!: 3.0 (#227)
* WIP

* chore: fix mix.lock merge issues

* improvement: upgrade to 3.0

* chore: remove `repo.to_tenant`

* chore: continue removal of unnecessary helper

* chore: use `Ash.ToTenant`
2024-03-27 16:52:28 -04:00
Zach Daniel
ec75b41dbe improvement: properly show unsupported error expression 2024-03-22 14:20:38 -04:00
Zach Daniel
2c1381d5e6 fix: encode maps on update using fragments 2024-03-19 00:06:15 -04:00
Zach Daniel
70af9ee5bd fix: always exclude :order_by on bulk updateable query 2024-03-05 09:19:55 -05:00
Zach Daniel
fce0fefe72 fix: don't apply join relationship sort for lateral join
fixes #218
2024-03-04 00:10:57 -05:00
Zach Daniel
2b3b6b0bc9 fix: properly leverage subqueries throughout relationship joining 2024-02-28 21:22:54 -05:00
Zach Daniel
6455bef6ed fix: ensure select is applied (or not) properly in bulk update/destroys 2024-02-25 21:35:33 -05:00
Zach Daniel
b6b2dd1dc6 fix: handle more subquery filter cases for aggregates 2024-02-24 20:20:52 -05:00
Zach Daniel
98f24b1923 Revert "fix: remove buggy global filter extraction"
This reverts commit 7c3b60b942.
2024-02-24 17:35:43 -05:00
Zach Daniel
7c3b60b942 fix: remove buggy global filter extraction 2024-02-24 17:20:03 -05:00
Zach Daniel
8fa10ac6ec fix: only apply filters inside aggregate subquery 2024-02-24 17:10:01 -05:00
Zach Daniel
37cb3825f1 fix: properly handle complex types in lists 2024-02-23 20:53:19 -05:00
Zach Daniel
c185ba80e8 fix: ensure select is properly set on delete_all 2024-02-21 16:37:28 -05:00
Zach Daniel
d0041ce88d improvement: optimize aggregate query filtering 2024-02-21 14:03:28 -05:00
Zach Daniel
2b91ebe488 fix: ensure proper return value for single aggregate runs 2024-02-21 09:56:33 -05:00
Zach Daniel
6e81afb24b fix: don't sort a query that will be used with delete_all
fix: ensure that `exists?` aggregates use `repo.exists?`
2024-02-21 07:54:58 -05:00
Zach Daniel
38d1beb0d8 fix: properly handle to_many joins in aggregates
fix: honor aggregate query filters
2024-02-20 18:38:35 -05:00
Dmitry Maganov
d2500b25f3
fix: properly transfer table names to non-inner wrapper queries (#210) 2024-02-20 11:15:06 -05:00
Zach Daniel
40522aadd8 chore: properly set __ash_bindings__ on bulk updatable query 2024-02-19 13:49:11 -05:00
Zach Daniel
f9a59cc5f6 chore: update style for credo 2024-02-19 13:35:36 -05:00
Zach Daniel
557bc6019c fix: handle non-inner joins in delete_all
fix: handle non-inner joins in update
2024-02-19 13:29:41 -05:00
Zach Daniel
7cbe482fc9 fix: don't update_all or delete_all with order_by 2024-02-19 12:40:26 -05:00
Zach Daniel
0979756b0b fix: handle updating from queries w/ non-inner initial joins 2024-02-19 11:56:48 -05:00
Zach Daniel
930d16a5e9 fix: handle original data not available in destroy_query 2024-02-12 10:08:48 -05:00
Zach Daniel
c72b57ece5 fix: use primary key of source as join key 2024-02-06 12:39:16 -05:00
Zach Daniel
43b576e09d fix: use pkey if error fields is empty 2024-02-01 15:48:23 -05:00
Zach Daniel
4494bf971f chore: changeset.resource -> resource 2024-02-01 15:21:50 -05:00
Zach Daniel
de7d6feaa3 fix: forgot to bind keys to a variable 🤦🏻 2024-02-01 15:12:17 -05:00
Zach Daniel
a940022eba fix: ensure identity keys is never missing 2024-02-01 14:59:49 -05:00
Zach Daniel
d71cb81792 improvement: handle if select is present on query 2024-01-31 16:30:23 -05:00
Zach Daniel
ffafa6c9f5 improvement: support Ash.Changeset.OriginalDataNotAvailable 2024-01-30 12:49:52 -05:00
Zach Daniel
7b9929f07c chore: format 2024-01-29 10:36:20 -05:00
Zach Daniel
98b1d2ad6c improvement: error_fields for custom_index
fix: proper return types for updates from queries
fix: allow atomics to return `nil`
2024-01-27 10:02:57 -05:00
Ryan
64e117603a
fix: Correct the matching used in building a distinct expression (#196) 2024-01-26 15:04:54 -05:00
Zach Daniel
29da61d661 chore: format 2024-01-24 12:49:38 -05:00
Zach Daniel
9926d5cb7c fix: only rollback to savepoint on specific errors 2024-01-24 11:37:24 -05:00
Zach Daniel
445de282c0 fix: remap selected fields, don't subquery in aggregate joins 2024-01-19 20:13:42 -05:00
Zach Daniel
9b5acd98f7 chore: credo, dialyzer, format 2024-01-10 08:34:23 -05:00
Zach Daniel
8bfa3ffa08 fix: don't overwrite manually set schema on lateral join query 2024-01-10 08:19:21 -05:00
Zach Daniel
a60dbf1725 fix: properly configure polymorphic_name option 2024-01-08 08:39:13 -05:00
Zach Daniel
65180ec3ac fix: honor configured schema on bulk create 2024-01-05 10:01:40 -05:00
Zach Daniel
c0c9621534 improvement: support new bulk operations
fix: support encoding errors with expressions in them
2023-12-31 08:40:30 -05:00
Zach Daniel
2a2fd30e33 improvement: support new return_query/2 callback
improvement: support new `:no_rollback` error signal
2023-12-29 21:49:34 -05:00
Zach Daniel
68e2f74fe0 improvement: support aggregates using other aggregates
fix: various fixes for unnecessary aggregate additions
test: added a test to confirm context based multitenancy behavior
2023-12-22 21:14:40 -05:00
Zach Daniel
5d246cc23b chore: take proper args from codegen args 2023-12-22 15:11:49 -05:00