Match set 

If a match set is specified, this position in the search pattern can be replaced by the exact number of characters specified in the match set.

Syntax

<match set> ::= <underscore> | ? | X'1E' | <match char>
| ([< Ù
(only for code type EBCDIC) | ~ (only for code type ASCII) | Ø >]<match class>...)

<match char>    ::= any character except %, *, X'1F', underscore, ?, X'1E', (.
<match class>   ::= <match range> | <match element>

<match range>   ::= <match element>-<match element> (character range)

<match element> ::= any character except )

underscore

Explanation

A LIKE predicate is used to search for character strings that have a certain pattern. Match sets can be used to specify the pattern ( pattern element).

Model table: customer

Finding all customers whose names consist of six letters and begin with 'P':

SELECT name, city FROM customer
WHERE name LIKE 'P?????'

NAME

CITY

Porter

New York

Peters

Los Angeles