In the course of our discussions about JMS messages and the JMS API, we reviewed the use of message selectors and examined JMS exceptions. As discussed in Chapter 3, JMS enables fairly sophisticated patterns to be defined for message selectors, and the rules regarding selector syntax defined by JMS are extensive. In Chapter 4 we saw that JMS defines a number of exceptions that standardize the reporting of basic error conditions.
The rules that define message selector syntax and govern the throwing of specific exceptions are reproduced here for your convenience from JMS Specification version 1.1, April 12, 2002.
A message selector is a
String whose syntax is based on a subset of the SQL92* ...