Skip to content

Add SyncMetadata.ID#271

Merged
mbrandonw merged 4 commits into
mainfrom
metadata-ids
Oct 24, 2025
Merged

Add SyncMetadata.ID#271
mbrandonw merged 4 commits into
mainfrom
metadata-ids

Conversation

@stephencelis
Copy link
Copy Markdown
Member

We can use a multi-column @Selection to represent SyncMetadata's composite primary key, which provides a more straightforward API for joining into the SyncMetadata table:

RemindersList
  .leftJoin(SyncMetadata.all) { $0.syncMetadataID.eq($1.id) }

This also provides a straightforward API for fetching sync metadata for a given ID:

SyncMetadata.find(reminder.syncMetadataID)

@mbrandonw mbrandonw merged commit 97b0f96 into main Oct 24, 2025
12 of 15 checks passed
@mbrandonw mbrandonw deleted the metadata-ids branch October 24, 2025 16:13
bok- pushed a commit to bok-/sqlite-data-with-traits that referenced this pull request Dec 15, 2025
* Introduce `SyncMetadata.ID`

* wip

* wip
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants