More in this section
Forums / Developing with Sitefinity / Query Dynamic Content with Multiple Related Data Items

Query Dynamic Content with Multiple Related Data Items

The forums are in read-only mode. In case that you want to directly contact the Progress Sitefinity team use the support center. In our Google Plus group you can find more than one thousand Sitefinity developers discussing different topics. For the Stack Overflow threads don’t forget to use the “Sitefinity” tag.
1 posts, 0 answered
  1. Ryan
    Ryan avatar
    0 posts
    22 May 2017
    28 Aug 2017
    Link to this post
    I was referring to this article for querying dynamic content with related data:

    This is all well and good, but currently I am dealing with this scenario:

    I have a custom content item of Human, and two related data items of type Hair Color and Eye Color (these are just example types of course)

    Suppose I wanted to query all Human items with Hazel eyes and black hair, how can I do that in a clean way?

    I came up with a hacky solution, but I need something that will work with either no related data query needed, or with one or both (all combinations)

    Is there a tried and true way of doing this with Sitefinity's native API? Code samples would be much appreciated thank you :)
1 posts, 0 answered