- Issue created by @milindk
- Status changed to Needs review
about 1 year ago 12:15pm 20 September 2023 - @milindk opened merge request.
- 🇨🇦Canada mandclu
How is the "match_phrase" you're proposing different from the "match_entire_string" feature that the module already has?
- 🇮🇳India milindk
Its different with conjunction, basically the AND conjunction is meant for searching whole string for overrides. but we need to give a way where the phrases can be searched for OR conjuctions.
The trouble is with "match_entire_string" is that it has no effect for searches that use the "OR" conjunction due to this if condition:
if (count($query_keys) > 1 && ($conjunction == 'AND'))
Even in "OR" searches, the only two options you would want are either matching all the individual words in addition to the entire phrase, or matching only the individual words and not checking the full phrase itself. This is exactly the way it is treated when the conjuntion is "AND", so I would advocate for it being simply:
if (count($query_keys) > 1)
Then we could just continue using the "match_entire_string" setting to control this without a need for additional option.
- 🇺🇸United States j-barnes
@Bradley-B - Removing the
&& ($conjunction == 'AND')
worked great for our use case. We use "Contains Any" for our full text search, which does not appear to work correctly in conjunction with "match_entire_string". Thanks!