Back

[SOLVER] Fulltext search not work in flutter

  • 0
  • Flutter
tuyen3962
26 Dec, 2023, 02:28

I use the latest version of Appwriter in flutter but when i setup the fulltext index key for the attribute, I can not search the related keyword basing on the field. Example: I combine two user id as the string and set it into the field named member_ids, and i use my user id to search but it is not returned for me the result as i expected after i have created the document.

TL;DR
User is experiencing issues with fulltext search not working in Flutter with Appwrite. They are using the latest version of Appwrite and have set up a fulltext index key, but are not getting the expected results when searching for a keyword in the specified field. There seems to be a limitation with MySQL/MariaDB that only allows searching from the beginning of each word. The user is currently using a workaround by using the "start with" and "end with" query, but it is inconvenient. The user asks if there is a way to format the text for searching with the word anywhere in the sentence. Solution: The current limitation
ideclon
26 Dec, 2023, 02:58

Fulltext search only searches from the beginning of each word, IIUC

tuyen3962
26 Dec, 2023, 03:33

Oh

tuyen3962
26 Dec, 2023, 03:34

I assume it can work with the text in the everywhere in the sentense

ideclon
26 Dec, 2023, 03:43

Yeah, I assumed that too, at first! I belief the fulltext search in Appwrite is basically MySQL fulltext search.

ideclon
26 Dec, 2023, 03:44
  • Each term to be searched (in the database) should be comma separated.
  • Each searched term needs to be at least three characters
  • Common English words (like, and, but, etc) will be ignored
tuyen3962
26 Dec, 2023, 04:19

So can i format text for searching with the word place anywhere in the sentense?

ideclon
26 Dec, 2023, 05:30

You should be able to search for any word within a sentence, I believe. Your search term just needs to start at the beginning of the word.

ideclon
26 Dec, 2023, 05:31

So “sent” would find “sentence”, but “tenc” would not

tuyen3962
26 Dec, 2023, 05:32

Because i want to search with the case 'tenc' for simple

tuyen3962
26 Dec, 2023, 05:33

Now i use the start with and end with query for searching data

ideclon
26 Dec, 2023, 05:33

To my knowledge, this is not currently possible

tuyen3962
26 Dec, 2023, 05:33

It is unconvinient

tuyen3962
26 Dec, 2023, 05:33

Oke thank sir

tuyen3962
26 Dec, 2023, 05:33

Hope this can be updated in the future

ideclon
26 Dec, 2023, 05:34

*inconvenient?

tuyen3962
26 Dec, 2023, 05:34

My english is not good so i am sorry for that

ideclon
26 Dec, 2023, 05:35

So do I! But to my knowledge, this is not an Appwrite limitation - it’s a MySQL (or to be more accurate, MariaDB) limitation

ideclon
26 Dec, 2023, 05:36

That’s fine - I’m sure my grasp of your native language is far worse than your grasp on mine (English)!

ideclon
26 Dec, 2023, 05:37

If your issue has been solved, you can mark this post as closed by adding “[SOLVED]” to the beginning of the title

tuyen3962
26 Dec, 2023, 05:42

Oke sir

tuyen3962
26 Dec, 2023, 05:43

[SOLVER] Fulltext search not work in flutter

Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more