Skip to Content

Product Search - like instead of equals

Hello everyone, When I search "pen" getting results only for "pen". I want to see "pencil" results and all results that begin with "pen" too. How can I solve it?

Add a comment
10|10000 characters needed characters exceeded

Related questions

2 Answers

  • Best Answer
    Posted on Feb 06, 2018 at 08:06 AM

    I was asked for product search from frontend with text search and I have found solution. Configuring free text query properties from indexed type has solved my problem.

    alt text alt text


    10346-ss2.png (41.9 kB)
    10347-ss1.png (40.0 kB)
    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Feb 05, 2018 at 06:33 AM

    It behaves similarly to SQL. So you can use % as wildcard:

    • LIKE 'pen%' to get pencil

    • LIKE '%pen' to get ballpen

    • LIKE '%pen%' to get appendix

    Please don't forget to upvote and accept answer, if it's what you're looking for.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.