Previous Section Next Section

-a

Append tag on successful match V8.1 and above

When a key is looked up in a database (from inside the $( and $) operators of the RHS of rules), a successfully found key is replaced by its data. If the -a switch is given, the text following that switch, up to the first delimiting whitespace character, is appended to the replacement data. For example:

-a              appends  nothing 
-a.             appends  .
-a,MAGICTOKEN   appends  ,MAGICTOKEN

The text to be appended is taken literally. Quotation marks and backslashed characters are included without interpretation, so whitespace cannot be included in that text. Because the rewritten RHS is normalized as an address, special address expressions (such as parentheses) should be avoided. The use of appended text is one of two methods used for recognizing a successful lookup in rules. We'll discuss the other, $:, in Section 23.4.1.

    Previous Section Next Section