Data Access Getting Started > Database Features > Using Selection and Display Criteria > Additional Information about Selection Criteria
 
Additional Information about Selection Criteria
You can use the following operators in the SQL Data Source inspector to define selection criteria used by the data source to retrieve values from the database tables. Use the Select page when no Operation is defined in any of the columns; otherwise, use the Having page. The following expressions can be used with most database management systems. You can also use any expression supported by your particular system.
= 4
Equals
<> ‘Smith'
Different than
< 56
Less than
<= 8979
Less than or equal to
> 78
Greater than
>= 876
Greater than or equal to
LIKE 'ABCD%'
(all words beginning with ABCD)
LIKE 'A_B'
(all words where “_” equals any one character)
between 1 AND 5
(all numbers between 1 and 5)
Where row  The criteria typed in the Where cell of each column is added with an SQL logical AND operator to WHERE criteria in other columns to further restrict the selection. If a cell is left empty, the column is not taken into account for defining the selection criteria.
Or rows  When you add criteria in a Where cell and validate it, a new row labeled “Or” appears below the Where row. The cells in the Or row are used just like those in the Where row. An SQL logical AND operator is used with each cell to further restrict the criteria. To provide further choices, an SQL logical OR operator is used between each of the Where and Or rows. Multiple Or rows are possible.
Here is an example of using the Where and Or rows:
The Where and Or rows are read as follows:
Select all the employees whose employee number is greater than or equal to 200,
AND whose department number is not 2,
AND whose salary is greater than 2000;
OR
all the employees whose employee number is less than 100,
AND whose department number equals 4,
AND whose salary is less than 1000.
Since the Name cell is left blank, any employee name can be selected if all the other criteria are met.

Version 6.2.1
Copyright © 2018, Rogue Wave Software, Inc. All Rights Reserved.