Querying tables

To query a table, first activate the table by clicking the pointer within the table window. Then, follow the steps below to perform the query.

  1. From the "Table" menu, choose "Query". The "Query Table" dialog will appear.

  2. At the top of the box, use the pull down menu to show the possible variables that you can query, and highlight one variable name.

  3. Pull down the "Operator" list in the next box, and choose the description that fits the query you would like to do (e.g. "equal to," "less than or equal to," "greater than").

  4. Select whether the variable you are going to query on is a number or a string (character variable) by clicking on the appropriate dot. Then type the value or string in the box below. If you choose a string, you will need to enter the value in double quotes (e.g., "A").

  5. Next, you need to decide what to do with the results of the query. If you haven't already selected any rows of data, choose "New Set." If you want the rows that are the results of your query to be added to an existing selected set, choose "Add to set." If you want the query to only look within a selected set when choosing rows (leaving only the results of the query highlighted), choose "Select from set." The rows are immediately selected (highlighted) in the table.

  6. When you have completed your selection, choose "Close." The values that meet your query will be highlighted. If you have a large data set and multiple rows meet your criteria, you may want to promote selected rows to view them all at the same time.


See also: