objectbox-java: duplicate results in queries
I have more than one condition like
myObjectBox.query()
.equal(MyObject_.relatedObjectId, 1)
.less(MyObject_.date, date)
.build().findIds()
on a object collection like
{id, relatedObjectId, date}
{1,1,2017-05-20},
{2,1,2017-05-21},
{3,1,2017-05-22},
{4,1,2017-05-23},
with date {2017-05-22} (including some time) i get the following result {1,2,3,1}
Why the hell is there a 1? I tried “life” on a debugger with an additional comparison to the relatedObject and got the result {1,1,2,3} - still not the thing i want to get. If I try to order them I get the error, that I just can use this option on unordered requests. That is strange and think its an issue. If I am wrong, tell me what I do wrong (the code is nearly a copy with some anonymizing of the variables)
About this issue
- Original URL
- State: closed
- Created 7 years ago
- Comments: 15 (6 by maintainers)
I can confirm that this solved my issues of having duplicates in results.