Sybase 2 Barcode Reader User Manual


 
Using Quick Select
118 DataWindow .NET
SQL expression examples
The first six examples in this section all refer to a grid that contains three
columns:
EmpId, DeptId, and Salary.
Example 1
The expression <50000 in the Criteria row in the Salary column in the grid
retrieves information for employees whose salaries are less than $50,000.
The
SELECT statement that DataWindow Designer creates is:
SELECT emp_id, dept_id, salary
FROM employee
WHERE salary < 50000
Example 2
The expression 100 in the Criteria row in the DeptId column in the grid
retrieves information for employees who belong to department 100.
The
SELECT statement that DataWindow Designer creates is:
SELECT emp_id, dept_id, salary
FROM employee
WHERE dept_id = 100
Example 3
The expression >300 in the Criteria row in the EmpId column and the
expression
<50000 in the Criteria row in the Salary column in the grid retrieve
information for any employee whose employee ID is greater than 300 and
whose salary is less than $50,000.
The
SELECT statement that DataWindow Designer creates is:
SELECT emp_id, dept_id, salary
FROM employee
WHERE emp_id >300 AND salary <50000