DEFAULT_LIKE_MATCH_SELECTIVITY_PPM option

Function

Provides default selectivity estimates (in parts per million) to the optimizer for most LIKE predicates.

Allowed values

0 to 1000000

Default

150000

Scope

Can be set for an individual connection or the PUBLIC group. Takes effect immediately.

Description

DEFAULT_LIKE_MATCH_SELECTIVITY_PPM sets the default selectivity for generic LIKE predicates, for example, LIKE 'string%string' where % is a wildcard character.

The optimizer relies on this option when other selectivity information is not available and the match string does not start with a set of constant characters followed by a single wildcard.

If the column has either an LF index or a 1- or 2- or 3-byte FP index, the optimizer can get exact information and does not need to use this value.

Users can also specify selectivity in the query, as described in the section “User-supplied condition hints” in the “Search conditions” section in Chapter 2, “SQL Language Elements” in Reference: Building Blocks, Tables, and Procedures.

See also

“DEFAULT_LIKE_RANGE_SELECTIVITY_PPM option” and “FP_LOOKUP_SIZE option”.

“The Fast Projection (FP) default index type” in Chapter 6, “Using Sybase IQ Indexes” in System Administration Guide: Volume 1

“LIKE conditions” in Chapter 2, “SQL Language Elements” in Reference: Building Blocks, Tables, and Procedures

Chapter 3, “Optimizing Queries and Deletions” in the Performance and Tuning Guide