Example: Using Select Pane Templates

This example shows how to use Select pane templates to make selections in various ways.


We will work with the Customers table from the ubiquitous Nwind example database.



With the focus on the Customers table window, in the Select pane choose the Company Name field.   The Select pane will automatically load with templates that can be used with text fields, like the Company Name field.


Double-click on the Search template to choose it.    The Search template will launch in the Select pane, with controls configured to allow choosing options for using the Search template.



In the Search template text is the default Use option, meaning we will be selecting using the text in the Contact Name field.  


From the long list of options in the Condition pull down menu, we choose contains as the Condition option.   The default setting for Value allows us to enter the text that interests us, to select records where the Contact Name field contain the text we enter.



We enter As into the Value box, and then we press Preview to get a preview of what will be selected, that is, all records which have the letters As in their Contact Name field.



Two records are previewed in blue preview background color, one because it has the text sequence as and the other because it has an As sequence.   The Collation we are using is a neutral, nocase setting (easy to change by pressing the collation picker button) so case is not significant.  The preview also overlays on the column header section of the table a blue background virtual column header titled Search, the name of the template we are using, to indicate we are seeing a preview.



We alter the Value to search for making it An.     


We also click the collation picker button and choose the neutral collation from the list of favorites that pops up.  Collations allow us to set options like nocase for case insensitivity, ignoring accents, or choosing different languages and language settings for our searches.  Removing the nocase option means the search is now case sensitive.


Press Preview.



The preview shows that only those records which have in their Contact Name field a pattern of a capital A followed by a lower case n will be selected.



The Action option of replace selection means that when we press the Select button, the selection we have set up will completely replace any previous selection in the table.   


Other choices for Action are add to selection, intersect with selection, invert with selection or subtract from selection.   Different action settings provide different ways to combine the selection we have just constructed with any previously existing selection in the table.


Press Select.



The template selects the records, replacing any previous selection, and the table shows the selected records in red selection color.    The preview disappears.



The settings in the Select pane are still there unchanged.   We can change the Field that is the subject to any text field in the table.  The pull down menu for the Field box will be loaded with all text fields in the table, so we pick Company Name.   


In the Value box we enter Tru.  


Press Preview.



As before, the proposed selection is previewed in the table.  It appears in a tinted blue color that is a blend of the red selection color and the blue preview color, since the record being previewed was also already selected.



To remove previewed records from the selection we first choose subtract from selection for the Action option.   



Press Select.



The record with Tru in the company name is subtracted from the selection.


The Action option setting persists: it will remain subtract from selection until we change it back to replace selection.  This is convenient for repeated operations using the same setting, but if we will not be repeating subtractions, it is best to get in the habit of resetting the Action option back to replace selection, to avoid surprises.

Turning off Previews

When we press Preview in the Select pane, a preview using blue preview color automatically appears.   Previews will persist, and will stay visible even if we change to different windows.  That allows us to do other work while seeing the preview, to guide our other work or to compare it to the preview.



Suppose we choose the starts with option for Condition, using a Value of B to find all company names that start with B.


Press Preview.



The table automatically shows a preview using blue preview color.



To hide the preview, we right-click on the Search virtual preview column header and choose Hide Preview from the context menu.



That will show the table without any previewing in blue preview color.  If we want the preview back, we simply press the Preview button again.


See Also



Select Pane


Example: Using Select Pane Expressions - Make selections by writing snippets of SQL into the Select pane Expression template.


Example: Construct JSON String using Select and Transform - Use the  Select pane and Transform pane to manually construct a JSON string using values from other fields in a table. Shows how we can manipulate text to build desired contents in a field.