Conditional Dropdowns: Basic Setup

Before you get to setting the Conditional Behavior property, there's work to do. The most basic and recommended method involves completing these steps:

  1. Create three tables in your application.

  2. Create three one-to-many relationships among your tables.

  3. Enter data.

  4. Modify field properties to set up your conditional field. The field properties let you define the conditions that determine what appears in the resulting dropdown list.

Each of these steps is more fully explained in the tutorial below. You can follow the steps in this tutorial to set up the application used in the example above.

Note: While this is the most common and the recommended way to create conditional dropdowns, you can choose another method. Click to learn how.

Tutorial: Creating an Employee HR application with conditional dropdowns

Follow this tutorial to set up an application with that allows you to enter employee names, countries, and cities. The Add Employee form should contain a conditional dropdown, allowing you to filter the cities list based on the selection of the employee's country.

employee_countrycallout.png employeeform_callouts.png

 

Step 1: Create an application with three tables

While your actual application may include many more than three tables, to achieve the conditional dropdown shown in the example form, you need to create at least the tables and fields shown in the table below:

 

Table

Fields (all of type Text)

Description

Employees

  • Last name

  • First name

 

You'll record all information about each employee in this table.

Countries

Country

Use this table to store the names of all countries where your company has at least one office.

Cities

City

 

Use this table to store the names of all cities where your company has at least one office.

Step 2. Create three one-to-many relationships

Each of your tables needs to know something about at least one other table in your application:

So, you should set up these three relationships:

employeeapparelationships.png

The relationships should be set up this way because:

How reference fields help you with conditional dropdown lists

 

When you create this relationship...

...QuickBase creates these reference fields in the Details table.

How these reference fields help you create conditional dropdowns

Countries -< Cities

Related Country

 

Having the Related Country field in the Cities table lets you pair each city with a country.

Countries -<Employees

Related Country

Having the Related Country field in the Employees table lets you associate each employee record with the right country.

Cities -< Employees

Related City

The Related City field in the Employees table is your conditional field. Having this field in the Employees table lets you associate each employe with the right city. It also lets you set up conditional behavior that allows you to specify that QuickBase should check the selection of the employee's country and then filter the Related City list accordingly.

 

For now, just make note of the reference  fields that QuickBase created. You'll use these later in the process.

Step 3: Enter data in your application

Populate your Countries and Cities tables as follows:

Countries

Cities

Canada

  • Toronto

  • Vancouver

England

  • London

  • Westminster

France

 

Paris

 

United States

  • Boston

  • Chicago

  • New York

  • San Francisco

 

Step 4: Set Conditional Behavior properties for your conditional field

Remember that your goal is to create a form where you can enter employee information and be able to filter the City list based on the employee's country. You can see that your Employee table now contains these reference fields: Related Country and Related City fields.  The field you want to define as conditional is the Related City reference field in the Employee table.

To set Conditional Behavior properties for your conditional field:

  1. Access the field properties of the Related City field in the Employees table

    .conditionalbehavior.png

  2. Check the Filter choices by selecting another field first option. (Note: You'll see this option only in the field properties for reference fields; if you don't see it, you may have chosen the wrong field by mistake.)

    QuickBase asks you select fields to complete this statement:

    After <field1> is selected, Show only choices where <field1> = <field2>

  3. Set these conditions:

    1. In the first field, select Employees: Country. This tells QuickBase to check the selection of the Employees: Country field to determine which cities to display..

    2. In the second field, select Cities: Country. This tells QuickBase to display only those cities that belong to the country the user selected.
      QA_proxyfield.png

    3. Click Save.

Cleaning up your Employee form

Depending on the order in which you created your relationships, your Employee form may contain an extra field (City --Related Country). If this is the case, simply edit your form properties and remove the field from your form

Testing  your conditional dropdown

Once you've completed these steps, you can test your conditional dropdown by adding a new employee, Colleen Garton, to your Toronto office.

To test the conditional dropdown:

  1. Click Employees > Add an employee.

  2. Enter Garton and Colleen, for Last name and First name, respectively.

  3. In the Country field, select Canada.

  4. Click the Cities dropdown. QuickBase displays only Canadian cities: Toronto and Vancouver.

  5. Select Toronto and click Save.

Related Topics

 

Return to top

© 1999-2011 Intuit Inc. All rights reserved. Legal Notices.