I am using SXA 1.7 and need to add a Query item under my variant definition, I found that the query should be written using sitecore query format like "query:./*" to return the child items but it doesn't return the data.

Also I need to know, how the child items field will be displayed, should I define the variant fields under the Query node in thevariant definition?

  • yes, define how items from the query will be rendered by adding variant fields under query item. The query works fine, make sure you define how they should be displayed. Jun 24, 2018 at 15:13
  • Is the query field is available only for specific components as page content, for example if i am using search results, will it be available as well?
    – NAli
    Jun 24, 2018 at 18:31

1 Answer 1


Here is how you define what will be displayed from items returned by Variant Query, it's quite simple:

enter image description here

If you are not sure if your query is working then make a quick test like in above example. Drop Page Content on the Home item, add some pages under the home and if you will put following query query:./* in the Query field of Variant Query it should return Home children:

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.