Creating a dynamic array to populate multi select field

Options

I have a search form that has a multi-select field for location, in this case US states. Users can select one or more. What I was considering was querying my listing table to create an array list of the states currently represented by active listings.

Example is I have 10 listings in California, 5 in Florida, 2 in Texas. The array would return California, Florida, Texas. With this I could pre populate my search form so users are less likely do have zero results returned.

I haven't taken a stab at this, but was curious as it seemed like a good idea for my project, if its possible with Xano to query the records, create the array, and serve it to my app?

Thoughts and comments welcome, and thanks in advance!

Tagged:

Comments