Generic values and characters with special meanings

The following information describes generic values, and characters that have special meaning when you build MQSC commands.

Wherever a parameter can have a generic value, it is entered ending with an asterisk (*), for example ABC*. A generic value means 'all values beginning with'; so ABC* means 'all values beginning with ABC'.

If characters that require quotation marks are used in the value, the asterisk must be placed inside the quotation marks, thus 'abc*'. The asterisk must be the last or only character in the value.

The question mark (?) and colon (:) are not allowed in generic values.

Character Description
  Blanks are used as separators. Multiple blanks are equivalent to a single blank, except in strings that have apostrophes (') round them. Any trailing blanks in those string attributes which are based on MQCHARV types are treated as significant.
, Commas are used as separators. Multiple commas are equivalent to a single comma, except in strings that have apostrophes (') round them.
' An apostrophe indicates the beginning or end of a string. IBM® WebSphere® MQ leaves all characters that have quotation marks round them exactly as they are entered. The containing apostrophes are not included when calculating the length of the string.
'' Single quotation marks inside a string are treated by IBM WebSphere MQ as one character when calculating the length of the string and the string is not terminated.
= On z/OS®, an equals sign indicates the start of a parameter value which is ended by a comma or blank.
( An open parenthesis indicates the beginning of a parameter value or list of values.
) A close parenthesis indicates the end of a parameter value or list of values.
: A colon indicates an inclusive range. For example (1:5) means (1,2,3,4,5). This notation can be used only in TRACE commands.
* An asterisk means "all". For example, DISPLAY TRACE (*) means display all traces, and DISPLAY QUEUE (PAY*) means display all queues with names that begin with PAY.

When you need to use any of these special characters in a field (for example as part of a description), you must enclose the whole string in single quotation marks.