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
When get parent's property using backlink, realm fire column does not exist exception on child item.
like Unhandled Exception: RealmException: Error getting property ChildModel.name Error: RealmException: Error code: 8 . Message: Column does not exist
Repro steps
run attached codes.
Version
0.7.0rc
What Realm SDK flavor are you using?
Local Database only
What type of application is this?
Flutter Application
Client OS and version
Flutter 3.3.7 ipadOS 16 android 12
Code snippets
void main() {
final realm =
Realm(Configuration.inMemory([ParentModel.schema, ChildModel.schema]));
final child = ChildModel(Uuid.v4(), 'key', 'name');
realm.write(() {
final parent = ParentModel(Uuid.v4(), 'pkey', 'pname');
realm.add(child);
realm.add(parent);
parent.children.add(child);
});
print(child.name);
print(child.parents.first.name);
}
@RealmModel()
class $ParentModel {
@PrimaryKey()
late Uuid uniqueId;
@Indexed()
late String key;
@Indexed()
late String name;
late List<$ChildModel> children;
}
@RealmModel()
class $ChildModel {
@PrimaryKey()
late Uuid uniqueId;
@Indexed()
late String key;
@Indexed()
late String name;
@Backlink(#children)
late Iterable<$ParentModel> parents;
}
What happened?
Can not get parent properties.
When get parent's property using backlink, realm fire column does not exist exception on child item.
like
Unhandled Exception: RealmException: Error getting property ChildModel.name Error: RealmException: Error code: 8 . Message: Column does not exist
Repro steps
run attached codes.
Version
0.7.0rc
What Realm SDK flavor are you using?
Local Database only
What type of application is this?
Flutter Application
Client OS and version
Flutter 3.3.7 ipadOS 16 android 12
Code snippets
Stacktrace of the exception/crash you're getting
Relevant log output
No response
The text was updated successfully, but these errors were encountered: