Search Logic

This topic contains 2 replies, has 2 voices, and was last updated by cnganga cnganga 7 years, 5 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #10622
    cnganga
    cnganga
    Participant

    Hi,

    I am trying to get the “AND” logic to work but any search criteria i enter does not bring back a result unless i use the “OR” logic. What i am trying to achieve is when a user enters a set of criteria e.g. breakfast eggs sunday the results that are brought back are all the content on my website that has all those word in them and order the results in relevance for the ones with all three come up first and the ones with two matches come second etc.

    Would you be able to assist.

    Regards
    Chris

    #10623
    Ernest Marcinko
    Ernest Marcinko
    Keymaster

    Hi Chris,

    With the default engine, the search logic works on a field basis – meaning that each keyword must match at least one of the selected fields. In case of “breakfast eggs sunday”, each word will have to match either the title, content or any of the selected fields. If the title matches “eggs” the content matches “breakfast” and “sunday”, it’s not considered as a match – because on database level this is not possible to distinguish.

    To resolve this limitation and optional Index Table engine was implemented to index posts and post_type object contents. You will find all the information and explanations on these documentation chapters:
    Index table introduction
    Generating an index table

    Best,
    Ernest Marcinko

    If you like my products, don't forget to rate them on codecanyon :)


    #10624
    cnganga
    cnganga
    Participant

    Thanks for your prompt response, i will give that a try later on this evening.

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.