You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a primary object that contains an embedded object. I receive updates from the server and would like to simply call realm.create(MyObj, data, Realm.UpdateMode.Modified).
However, these payloads are large and while we receive them in full during initialization, updates often contain partials of the embedded objects (I do not have control over the server data or how it is provided).
Currently, when upserting the parent, the embedded children are re-created rather than themselves being upserted.
I'm wondering if there's some way for me to stick with a 1-line upsert to update my db, or if I'm going to have to write a bunch of manual updates for the embedded objects.
Manually handle updates in the form of obj.emb.str = data.emb.str, however given the scale of the data (many many many primary objects that contain embedded objects), I'd really prefer just having a one line upsert if possible.
Convert embedded objects to primary, however many of these nested objects don't have properties that could be used as a primary key.
How important is this improvement for you?
Would be a major improvement
Feature would mainly be used with
Local Database only
The text was updated successfully, but these errors were encountered:
Problem
I have a primary object that contains an embedded object. I receive updates from the server and would like to simply call
realm.create(MyObj, data, Realm.UpdateMode.Modified)
.However, these payloads are large and while we receive them in full during initialization, updates often contain partials of the embedded objects (I do not have control over the server data or how it is provided).
Currently, when upserting the parent, the embedded children are re-created rather than themselves being upserted.
I'm wondering if there's some way for me to stick with a 1-line upsert to update my db, or if I'm going to have to write a bunch of manual updates for the embedded objects.
Solution
No response
Alternatives
obj.emb.str = data.emb.str
, however given the scale of the data (many many many primary objects that contain embedded objects), I'd really prefer just having a one line upsert if possible.How important is this improvement for you?
Would be a major improvement
Feature would mainly be used with
Local Database only
The text was updated successfully, but these errors were encountered: