Fundamentals > Family Tables > Searching in a Family Table > Example: Using Expressions to Perform a Family Table Search
Example: Using Expressions to Perform a Family Table Search
The following three examples illustrate how to use model expressions to search in a Family Table.
For example, assume a model with the following model parameters:
Parameter
Possible Sample Parameter Values
name
'bolt' or 'washer'
generic
'yes' or 'no'
level
a number between 1 and 9
These parameters and values are used in the following sample procedures.
Example 1: To Find Instances of a String Variable with Expression
To find all instances of the name: "bolt" parameter, you would perform the following procedure:
1. Perform a single-condition search using the Search dialog box.
2. Select Expression as your information type.
3. In the box below the Value list, enter the following:
name = "bolt"
* 
In a string search, you must include quotation marks around the name of the string variable.
The only permissible operators in a string search are = and !=.
4. Click Add to include this expression in the list of search criteria.
5. Click Find to begin the search, or complete steps 2 and 3 again to add other parameters.
Example 2: To Find Instances of a Yes/No Variable with Expression
To find all instances of the generic: yes parameter:
1. Perform a single-condition search using the Search dialog box.
2. Select Expression as your information type.
3. In the box below the Value list, enter the following:
generic = yes
* 
In a yes/no search, quotation marks are unnecessary.
The only permissible operators in a yes/no search are = and !=.
4. Click Add to include this expression in the list of search criteria.
5. Click Find to begin the search, or complete steps 2 and 3 again to add other parameters.
Example 3: To Find Instances of a Number Variable with Expression
To find all instances of the level parameter with a value of greater than 4:
1. Perform a single-condition search.
2. Select Expression as your information type.
3. In the box below the Value list, enter the following:
level > 4
* 
You need not put the variable in quotation marks.
Any of the operators (=,!=, <, or >) can be used.
Decimals are permissible.
Was this helpful?