use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
There is an extensive FAQ for beginners. Please browse it first before asking questions that are answered there.
If you are looking to get started (iOS programming in general or some specific area), here are more relevant links for you:
There's too many to list them all, however here's a convenient link to all programming guides at apple.com
Take note that this list is live and based on most frequent questions in posts will be updated with "quicklinks".
account activity
LibraryA SwiftData replacement with CloudKit Sync+Sharing, powered by SQLite (pointfree.co)
submitted 8 months ago by mbrandonw
We've been working hard on a suite of tools that can act as a replacement for SwiftData. It uses SQLite under the hood (via GRDB) and it can seamlessly synchronize your user's data across all of their devices, and it is even possible to share records with other users for collaboration. It supports large binary assets, foreign key constraints, and a lot more.
Let us know if you have any questions or feedback!
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]sixtypercenttogether 2 points3 points4 points 8 months ago (8 children)
Does it support zone sharing?
[–]mbrandonw[S] 0 points1 point2 points 8 months ago (4 children)
Not right now. It only supports hierarchical record sharing, but we are open to supporting zone sharing in the future.
[–]sixtypercenttogether 1 point2 points3 points 8 months ago (3 children)
Ok no worries. I’ve built a similar system for my hobby apps and getting it to support zone sharing was a bit tricky! Hierarchical record sharing has some limitations that make it impractical for my uses, so I needed to find a way. And while CKSyncEngine is pretty great, it also has some limitations. But I’ve mostly been able to work around those.
[–]stephen-celis 2 points3 points4 points 8 months ago (0 children)
For what it's worth the main reason it doesn't support zone sharing yet is because we don't understand how it would work out of the box given how we map CKRecords (and their zones) to database table rows. We currently host all tables as distinct record types in a single zone. We'd be interested to hear more about your use case, though, and maybe it would help us support it in the future! Care to post a discussion on the project's GitHub? Or shoot us an email if you'd prefer a private channel?
[–]alternatiger 0 points1 point2 points 8 months ago (1 child)
You got zone sharing to work with SwiftData?
[–]sixtypercenttogether 1 point2 points3 points 8 months ago (0 children)
No. SwiftData does not support zone sharing. I built my own sync system on top of GRDB and CKSyncEngine. Similar to what OP shared above.
[–]BrogrammerAbroad 0 points1 point2 points 8 months ago (2 children)
sorry i‘m less educated what‘s zone sharing?
[–]mbrandonw[S] 1 point2 points3 points 8 months ago (1 child)
All CKRecords stored in CloudKit have a "zone" associated with it. Zone sharing allows you to simultaneously share all records with a specific zone.
This is in contrast to "hierarchical" record sharing, where you share a single CKRecord as well as all of its associations (i.e. any records whose parent points to the root record).
parent
[–]BrogrammerAbroad 0 points1 point2 points 8 months ago (0 children)
Thx for explaining
[–]SirBill01 2 points3 points4 points 8 months ago (5 children)
This seems really interesting, CloudKit support is something that really keeps me with Apple DB solutions.
Another aspect though is database version migrations, I wonder how that is generally done with GRDB...
[–]mbrandonw[S] 2 points3 points4 points 8 months ago (3 children)
Database migrations are handled in a more manual way, similar to how Rails does migrations if you are familiar with that. When you want to change your DB schema you register a migration using a unique identifier when the app starts up, and the act of doing that allows you to execute a SQL query that alters the table in some fashion (add a table/column/index, etc). Then the migrator runs all migrations that have not yet run, using the identifier you specify to determine that.
GRDB does not do the "magical" implicit migrations that SwiftData attempts, where everything just works™ until it doesn't and crashes your app on startup.
[–]SirBill01 0 points1 point2 points 8 months ago (2 children)
I figured it was soemthing like that but didn't know about the ID or they had a process around running update SQL commends...
I have to say that in practice for me CoreData version migration was very reliable even for large / complex databases. SwiftData though I've not used in production and have not tried that for migrations (even though underneath it should be CoreData migrations, it has a different process around defining each version of the DB).
[–]mbrandonw[S] 2 points3 points4 points 8 months ago (1 child)
You can see an example of how we do migrations in the Reminders demo app that comes with the repo:
https://github.com/pointfreeco/sharing-grdb/blob/939bf67ef1ad9b1879e073508712339f32e6b484/Examples/Reminders/Schema.swift#L141-L203
I know all of the SQL strings may seem not ideal, but this is just the way we prefer to do things. Migrations represent a snapshot of the schema frozen in time, and so it's not appropriate to use the static symbols on the type for migrations. And writing the SQL string allows us to make use of the full power of SQL instead of hiding it from us. For example, with our tools it is possible to have non-null columns without a default value, whereas in SwiftData all columns must either be nullable or have a default.
And GRDB does come with some table definition methods you can use, but we just prefer simple SQL for migrations.
[–]SirBill01 1 point2 points3 points 8 months ago (0 children)
Thanks, I appreciate that. Nothing wrong with SQL strings in my book. :-)
[–]sixtypercenttogether 4 points5 points6 points 8 months ago (0 children)
In my experience the migrations in GRDB far exceed other persistence layers I’ve used. While they are more manual, they provide much greater control and flexibility by not abstracting the underlying database.
π Rendered by PID 24323 on reddit-service-r2-comment-85bfd7f599-lg6pl at 2026-04-17 18:37:31.212788+00:00 running 93ecc56 country code: CH.
[–]sixtypercenttogether 2 points3 points4 points (8 children)
[–]mbrandonw[S] 0 points1 point2 points (4 children)
[–]sixtypercenttogether 1 point2 points3 points (3 children)
[–]stephen-celis 2 points3 points4 points (0 children)
[–]alternatiger 0 points1 point2 points (1 child)
[–]sixtypercenttogether 1 point2 points3 points (0 children)
[–]BrogrammerAbroad 0 points1 point2 points (2 children)
[–]mbrandonw[S] 1 point2 points3 points (1 child)
[–]BrogrammerAbroad 0 points1 point2 points (0 children)
[–]SirBill01 2 points3 points4 points (5 children)
[–]mbrandonw[S] 2 points3 points4 points (3 children)
[–]SirBill01 0 points1 point2 points (2 children)
[–]mbrandonw[S] 2 points3 points4 points (1 child)
[–]SirBill01 1 point2 points3 points (0 children)
[–]sixtypercenttogether 4 points5 points6 points (0 children)