Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Valerie 67 posts 163 karma points
    Dec 08, 2014 @ 15:30
    Valerie
    0

    Examine API - Nested Or?

    Hello,

    I have a lucene query that looks like this

    (title:art bodyText:art tagSearchable:art) AND (typeSearchable:information OR typeSearchable:news)

    So basically I want to match anything that has e.g. art in the text / tags but is also an information or news type, for example.

    Is this possible?

  • Ismail Mayat 4511 posts 10059 karma points MVP 2x admin c-trib
    Dec 08, 2014 @ 18:26
    Ismail Mayat
    100

    Valerie,

    You can do 2 grouped ors with and AND in between

     

    query.GroupedOr().And.GroupedOr()

    Something along those lines have a look at the docs for exact syntax you have to pass in list of fields and second parameter is the list of values.

    Regards

    Ismial

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies