Copied to clipboard

Flag this post as spam?

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

  • Sven 30 posts 133 karma points
    Dec 11, 2020 @ 14:22

    Hello !

    i'm running into some issues trying to create a Examine Query.

    In my custom index I have a field called 'TestTaxonomy' with for example the following value: umb://document/75e97ba7f01c4723a258a243bf813a1c,umb://document/e936faa0f0eb4c62aeb993de3351a1f4

    In this value I would like to be able to search 1 value and return the item if the value is found.

    My current query:

     var results = _newsIndexSearcher.CreateQuery(IndexTypes.Content, BooleanOperation.Or)
                .GroupedOr(new string[] { "TestTaxonomy_" + _currentCulture }, allThemesUdis.ToArray())
                .Not().Field("__nodeId", newsItemId)
                .OrderByDescending(new SortableField("createDate"))

    This query works if my 'TestTaxonomy' field only has 1 value, however it goes wrong when there are more then 1 values.

    Examples in screenshot

    Thanks!enter image description here

  • Sven 30 posts 133 karma points
    Dec 15, 2020 @ 07:19

    Using .Fuzzy() was the solution for anyone wondering!

Please Sign in or register to post replies

Write your reply to: