Filter
Exclude
Time range
-
Near
Now that AshPostgres supports `MERGE`, we can finally have `Ash.update_many/4` in #AshFramework 😎. This allows you to do many row-wise updates each with their own unique input. This differs from `Ash.bulk_update/4` which updates a query or a set of records with *one* set of inputs. This might not seem that cool, but try hand-rolling this in a re-usable way with all of the various features that Ash supports (atomics, expression-based-updates, lifecycle hooks, etc.) and you'll get it 😂 This can be used for all kinds of purposes, but will soon be used to significantly optimize relationship management logic, i.e updating a to_many relationship with a set of inputs will now be three discrete queries, one to create anything new, one to update anything modified (with `update_many`) and one to remove anything left out. Take a look at the example code & representative SQL query: #ElixirLang
4
51
Replying to @ZachSDaniel1
All that ground work for such small, but useful QoL/DX improvements. > Sometimes it is fun to work on fancy new packages for #AshFramework To me, it’s as fun to work on fancy new projects using Ash.
2
225
Small thing I'm weirdly excited about in the next release of AshPostgres: upserts can now tell you whether each record was inserted or updated. Sometimes it is fun to work on fancy new packages for #AshFramework, but being able to focus on the core stuff is often more rewarding. This might sound easy, but the standard "INSERT ... ON CONFLICT" approach cannot generalize this without resorting to hacks that don't generalize to any given use case. Now you can just read `:upsert_action` from the result metadata — works for a single record or a whole bulk upsert. It's powered by a SQL `MERGE` under the hood now (PG17 ), which also quietly sets up something much bigger I'll be sharing soon 👀 Just have to update the `min_pg_version` callback on your repo to take advantage of it #ElixirLang
1
4
50
1,021
Hideki Takase retweeted
Got a few great submissions for the #AshFramework conference, but we need some more! If you're headed to #GoatMire, stay one day extra and join us! We're working on the venue/ticket details, but if you've got something to share, submit it here: sessionize.com/ash-conferenc…
2
14
605
Ash Framework | ashframework.bsky.social retweeted
For those in Sydney: the @ElixirSydney meetup is back after a pause, with two @AshFramework talks and a roundup of what's been happening across the BEAM ecosystem. Don't miss it! luma.com/6k7hotj8
1
7
241
Ash Framework | ashframework.bsky.social retweeted
1
3
172
I'm there! Looking forward to reporting my progress ;)
2
33
Thank you for a thorough response! I've already finished a book, and have some experience with Ash from one of my previous projects. Asked that question bc I believe we used Ash incorrectly there and had to fight with it (not very pleasant 😉). Anyway, going with it!
1
1
60
Use ash
1
77
😂
1
50
As your team lead, we do Phoenix first. Ash is cool, but on a big ERP you don’t want to debug your business logic and a framework religion at 2am. 😄
1
1
47
Ash LLM believe me it rocks!
1
40
So, no Ash? Why?
1
72
Jun 10
I'd even go so far as to say use the ash-hq project generator: ash-hq.org/#get-started
1
26
Jun 10
Ash for data model/business logic modeling always.
1
2
106
Honest thoughts, the learning curve is significant if not using AI. However, with AI, it really helps to keep it on the rails and quickly establishes patterns the AI can follow. Make sure you use the usage rules and ensure your AI knows about all the Ash libraries
1
62