I have a text attribute in a collection that has a full-text index on it. There are a number of documents that contain the value "r1_REPORT". When I perform a query of:
Query.search('sa_notes', "r1_REPORT")
I get no results. However, when I run a query of:
Query.search('sa_notes', "r1_R")
I get the result I expect. If there are any more characters present beyond the uppercase R, the search fails. I have tried using escaped quotes in the search too, but to no success.
How am I supposed to accurately query Appwrite for this?
We actually just received an issue similar to this...I think there's something weird going on with the underscore. related issue: https://github.com/appwrite/appwrite/issues/5546
can you use the startsWith query instead of search?
startsWith()
fails if I search for the full term, but succeeds if I search for "r1_REPOR"
I fairly recently upgraded to appwrite:1.3.4 and started noticing issues when trying to search like this in other areas - again with underscores.
yes...searching changed a bit in 1.3.x
Is this something that will be triaged, or left for a subsequent release?
We've only started investigating this.
That said, a release would need to be made to change this.
Okay. Good to know. Thanks.
Are things like this tested with new releases? This has pretty seriously crippled the application I've written with Appwrite.
It was working fine in < 1.3, but there was the severe limitations with search indexes, so it's not really practical to roll back either, sadly.
but it looks like underscores weren't tested
Recommended threads
- The current user is not authorized to pe...
I want to create a document associated with user after log in with OAuth. The user were logged in, but Appwrite said user is unauthorized. User is logged in wi...
- Attributes Confusion
```import 'package:appwrite/models.dart'; class OrdersModel { String id, email, name, phone, status, user_id, address; int discount, total, created_at; L...
- How to Avoid Double Requests in function...
I'm currently using Appwrite's `functions.createExecution` in my project. I want to avoid double requests when multiple actions (like searching or pagination) a...