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
Hello, I have the following query that works in mongo using a client, it uses an or operator which combines the result of a text index and a normal attribute.
However, I cannot create a query using the opOperator, because it only accepts Criteria and not TextCriteria. Why is that restriction? It is a feature that is not supported or there is another way create the query as described below?
val query= org.springframework.data.mongodb.core.query.Query()
query.addCriteria(Criteria().orOperator( textCriteria, hrNumberCriteria))
The text was updated successfully, but these errors were encountered:
Hello, I have the following query that works in mongo using a client, it uses an or operator which combines the result of a text index and a normal attribute.
db.getCollection('person')
.find(
{$or: [ { "hrNumber": "123"} , { $text: { $search: "123" } }] } )
However, I cannot create a query using the opOperator, because it only accepts Criteria and not TextCriteria. Why is that restriction? It is a feature that is not supported or there is another way create the query as described below?
The text was updated successfully, but these errors were encountered: