NonStop SQL/MP Reference Manual

Table Of Contents
NonStop SQL/MP Reference Manual142115
B-4
Examples—BETWEEN
The data type of the result of an expression in one row-value-spec must be
compatible with the data types of the results of the two expressions in the same
ordinal position in the others.
If you specify NOT, the predicate is true if the following condition is true:
( expr2 < expr1 OR expr1 > expr3 )
Specify NOT as follows:
expr1 NOT BETWEEN expr2 AND expr3
For a clause that specifies a column in a key BETWEEN expr1 and expr2,
expr2 must be greater than expr1 even if the column is defined as
DESCENDING.
Examples—BETWEEN
The following predicate finds those items for which the total price of the units in
inventory is in the range $1,000 to $10,000:
QTY_ON_HAND * PRICE
BETWEEN 1000.00 AND 10000.00
The following predicate finds those items for which the part cost is less than $5 or
more than $800:
PARTCOST NOT BETWEEN 5.00 AND 800.00
The following predicate finds those names between Jody Selby and Gene Wright.
The name Barbara Swift meets the criteria; the name Mike Wright does not.
LAST_NAME, FIRST_NAME BETWEEN
"SELBY", "JODY" AND
"WRIGHT", "GENE"
BLOCKSIZE File Attribute
BLOCKSIZE is a Guardian file attribute that specifies the number of bytes in a block.
BLOCKSIZE applies to key-sequenced, relative, and entry-sequenced tables, and to
indexes.
The default is BLOCKSIZE 4096.
num-bytes
is an integer that specifies the number of bytes in a block.
Block size can be 512, 1024, 2048, or 4096 bytes. If you specify a different block
size, SQL uses the next-higher block size and issues a warning. If you specify a
BLOCKSIZE num-bytes