Closed SecretKeeper closed 2 years ago
Yes, I just updated to ObjectBox 3.1.1 and noticed the same error as you. I saw something about this in the changelogs and checked the signature of the equal-function. There is now one variant of the equal-function with String which takes a third argument, StringOrder order:
io.objectbox.query.QueryBuilder#equal(io.objectbox.Property
, java.lang.String, io.objectbox.query.QueryBuilder.StringOrder)
The changelog mentions here:
For the existing Query API, String property conditions now require to explicitly specify case. See the documentation of StringOrder for which one to choose (typically
StringOrder.CASE_INSENSITIVE
).
That should fix it.
The same applies for the in-function.
@ajans Thanks for the summary!
@ourfamilygithub This project follows semantic versioning. So if there is a major release (e.g. 2.x.x -> 3.x.x) there are likely breaking changes. You can find details about changes in the change log or the releases page here on GitHub.
Closing as this appears to be resolved. ✅ Feel free to comment with more information or create a new issue.
i am sure this is bug for version +3.0.0 , because everything work well until 2.9.2-RC4
i have a model like this
val query = oBKeyValueBox.query().in(OBKeyValue_.key, arrayof("token", "user_id").build()
it throws
or
val query2 = oBKeyValueBox.query().equal(OBKeyValue_.key, "qqq").build()
and this one throws:
or any other queries it throws given error like this, it should work with String , because key or value field are string and you can use any type except String!!!!!
ONLY for equal you can use new syntax , but this just only work with equal and you can not use
in
or any other filters!!!:val query = oBKeyValueBox.query(OBKeyValue_.key equal key).build() // works
as i said it just happen on +3.0.0
any ideas?