How to Source Dropdown Options from a Data Table

How to Source Dropdown Options from a Data Table


Let’s say I have the below data table that holds the US states and their codes. 

On my form, I want to provide the form user with a field to select one of the 50 states. 


If you want to know how to upload a CSV file to create a Mirata Data Table, go to the Uploading Data to Mirata article.


In the Designer, follow the below steps on your form:

  1. Drag a dropdown component onto your form, at the desired location
  2. Name & label your dropdown 
  3. Go to the Data tab in the right panel 
  4. For Source Type, select Reference Table
  5. Table: Select your data table
  6. Return & Display: For Return, select the column from your table that holds the data you want to hold behind the scenes. For Display, select the column from your table that holds the values you want the form user to see. For example, this is how it would work for the above data set and selections: 
  1. Since I selected State for the Display value, then the user will select from the below list on the form:
  2. Since I selected Code for the Return value, if the form user selects California in the dropdown, then the value I will have behind the scenes is actually “CA”, not “California”. If I was creating a calculation to see if “California” was selected, I would be checking that my dropdown field is equal to “CA”.
  1. Sort By & Sort Order: For Sort By, select a column from your table that you want to use to sort the Display list. You can select the Sort Order as either ascending or descending. In this example, the options in 6a are sorted by the State column of our data table.


If you want to take this one step further and learn how to set up dependent dropdowns using a data table query, click here to go to that article.