La Julianeira

Páginas: 2 (493 palabras) Publicado: 13 de abril de 2011
Case Selection
You can select cases by entering a case-selection statement in the box below. The case-selection or "where" statement has the following form:

where variable expressionrelational operator condition

Variable Expressions
You can specify a single variable or an expression involving several variables.

To insert a variable name, select the variable in the list box atthe right and then double-click.

All of the usual arithmetic operators [+ - / * ( ) ] are available for use in variable expressions.

Relational Operators
The following relational operators areavailable:

= equals
!= not equal
< less than
> greater than
= greater than or equal
& and
| or
, or (comma, used in a series)
! not

The modulus operator is also available:

%the remainder after division by the following operand

Examples
Examples of selection conditions given by "where" expressions are:

where sex = 1 & age < 50
where (income + benefits)/famsize< 4500
where income1 >= 20000 | income2 >= 20000
where income1 >= 20000 & income2 >= 20000
where dept = "auto loan"
where 'estimated price/earnings' > 50

Note that strings used incase-selection expressions need not be enclosed in double quotes unless they contain embedded blanks or logical or arithmetic operators. Fieldnames which contain blanks or such illegal characters must beenclosed in single quotes.

Wildcards ( * or ? ) are available to select subgroups of string variables.

where account = ????22
where id = 3*

(The first statement will select any accountsthat have 2's as the 5th and 6th characters in the string, while the second statement will select strings of any length that begin with 3.)

The comma operator ',' is used to list different values ofthe same variable name that will be used as selection criteria. It allows you to bypass lengthy "or" expressions when giving lists of conditional values.

where state = CA,WA,OR,AZ,NV
where...
Leer documento completo

Regístrate para leer el documento completo.

Conviértase en miembro formal de Buenas Tareas

INSCRÍBETE - ES GRATIS