Sorting results based on dynamic dropdowns

3 drop downs (Country, State, City)

Populating data based on selection. Country has a search for with a constraint based on dropcown country value which displays all results = to country selected.

How to sort further downline based on State, at the sametime keeping the results from all country displayed.

Same goes for selection of City and the sorting downline how to do so without jeopardizing full results displayed for entire state based on state selection?

attempted adding constraint on RepeatingGroup (Country = dropdown country’s value) which works perfectly as its a search for.

Applying a constraint(state = dropdown state’s value) downstream on the Group item which is a child of repeatingGroup doesnt yield proper results. Issue with subtracting and adding results based on state selection.

same scenario with city.

What is the structure of the data you’re displaying? Does the datatype have 3 fields for country, state, and city?

yes in City datatype, it has all (Country, state and city) they are all populating properly in the dropdowns, but not sorting properly past country in the deticated rendering field

So you’re wanting to display and filter a list of the city datatype? Some screenshots would be helpful

1st image is the setup where there is 3 different data types, they are each pooling from the selection upstream Country populates state, state populates City. working

2nd image is when country is selected which automatically displays all items in selected country. The setup is (search for Items: constraint → item’s Country = Country dropdown value) done so at the RepeatingGroup item level.

3rd image is placing a conditional at the text parents group level (missing the extra field option of “this item is visible” which is applied)

4th is the result which is the opposite of whats needed.

Are you trying to hide the first and third items because they’re in BC and not in Nova Scotia? If so, placing a condition on the text is not the way to do it.

Can you post a screenshot of the repeating group’s data source?

precisly, where would the conditional need to be placed if not text?

Ideally you’d have your database set up differently so you could do this with a search constraint rather than condition. But if you insist on using a condition then you’d group everything in the cell together and place the condition on that group

1 Like

what do you mean by set up differently? i have 3 different data types (Country, State, City) in Datatype City i have added the state and country, and in Datatype State i have added Country for each record.

the drop downs have conditionals: State populates based on country selected, and city populates based on state selected.

Is this a bad setup?

Post a screenshot of the datatype you’re showing in the repeating group

This is the data type you’re showing in the RG? Meaning the three rows with images are the datatype city? If so, do a search for City and add the constraints:

State = dropdown state’s value
Country = dropdown country’s value
City = dropdown country’s value

And check the box to ignore empty constraints