Announcement

Collapse
No announcement yet.

After upgrading, started needing to use "%" to "fast search/autocomplete" again

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • After upgrading, started needing to use "%" to "fast search/autocomplete" again

    After upgrading to the latest versions, it started needing to use % to search again.
    I think it is related to the use of FULL TEXT on the search (autocomplete)

    yuri​​​​​​​

  • #2
    Could you provide steps to reproduce. What name you search? How many characters you enter? Fulltext search returns empty result if the query is shorter than ft_min_word_len. By default it's set to 4, though recommend to set it to 3. So you need to enter at least 2-3 characters (* is appended automatically).

    Before the full-text search was not used for autocomplete. As result, for big tables autocomplete was unusable, it was processed too long.

    Another issue is that MySQL full-text may not search some words for unknown reason.
    Last edited by yuri; 05-06-2022, 06:23 AM.

    Comment


    • #3
      Originally posted by yuri View Post
      Could you provide steps to reproduce. What name you search? How many characters you enter? Fulltext search returns empty result if the query is shorter than ft_min_word_len. By default it's set to 4, though recommend to set it to 3. So you need to enter at least 2-3 characters (* is appended automatically).

      Before the full-text search was not used for autocomplete. As result, for big tables autocomplete was unusable, it was processed too long.

      Another issue is that MySQL full-text may not search some words for unknown reason.
      Yuri, first, I would like to thank you for watching this.

      I changed the config to accept 2 characters for query.

      The problem is when typing, for example

      "test" for a word where the name is query_test_3

      It will not find the query_test_3 unless I use "%test"

      when using %test, it works as expected.

      Before start using full text, it was working perfect.

      I changed the entity config to use Full text too. Rebuild database, etc.

      Comment


      • #4
        I don't know how it can be fixed, unfortunately. It would require too much changing that can't be afforded in a hotfix release. I never expected that some users will need contains-search in autocomplete. When full-text search is enabled it does the job searching by separate words. But it won't search when words are separated by underscore.
        Last edited by yuri; 05-07-2022, 05:58 PM.

        Comment


        • #5
          Originally posted by yuri View Post
          I don't know how it can be fixed, unfortunately. It would require too much changing that can't be afforded in a hotfix release. I never expected that some users will need contains-search in autocomplete. When full-text search is enabled it does the job searching by separate words. But it won't search when words are separated by underscore.
          I just can't understand why when I use % it works. Why not append it before? It is not possible?
          It is causing a lot of problems here. People just used to write any part of a text are now thinking that the object doesn't exist. False result on the search box...

          I can't believe just me are having this problem. Obviously we could teach people to use %. But is something that worked before...

          Comment

          Working...
          X