I have parent realm object like this:
public class Parentdb extends RealmObject {
@PrimaryKey
public long id;
RealmList<Child> childs;
}
and I want to remove all child's from parent for that I use this code:
realm.beginTransaction();
parentdb.childs.deleteAllFromRealm();
realm.commitTransaction();
Child child=realm.where(Child.class).findFirst();
after run this code child must be null right?
but it's not!!!
am I doing something wrong?
Basically you have more children in the database than just what belongs to that single
parentDb
object.