Wildcards are a common mechanism with all operating systems that allow for matching several file names with one character string. Wildcards are most frequently used on the DOS or OS/2 command line, but are also used in the Workplace Shell.

OS/2 understands two wildcard characters:

  1. The asterisk (*) character matches any sequence of characters (no character, one character, or many characters).

    For example, h*e will match he, house, and home.

  2. The question mark (?) matches exactly one character.

    For example, h??e will match home, but not he or house.

Wildcards can also be combined. For example, h*e.?xt will match house.txt.

Note that as opposed to DOS, the dot (.) in file names is not a special character, unless you are working with files on the FAT file system.