How can I create an and
operation with Realm?
Example I have an object with day and month and I want to check both those fields values.
Something like :
RealmResults<Event> toEdit = realm.where(Event.class)
.equalTo("day", day)
.and
.equalTo("month", month)
.findAll();
But as far as I can tell there is no and
operator.
Thank you
Multiple conditions are combined with And unless there's an .or()
between them, so it's just:
RealmResults<Event> toEdit = realm.where(Event.class)
.equalTo("day", day)
.equalTo("month", month)
.findAll();
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With