Microsoft Log Parser Toolkit

Functions are powerful elements of the Log Parser SQL language; virtually all queries written with the Log Parser SQL language make use of at least one function. Functions take zero or more field-expressions as arguments, process their values, and return a new value. The Log Parser SQL language supports more than 80 functions, ranging from string manipulation functions (for example, SUBSTR, STRCAT) to arithmetical functions (for example, ADD, EXP).
The ADD function returns the sum of the two argument values.
<b class="bold">ADD( addend1 </b><<b class="bold">any type</b>><b class="bold">, addend2 </b><<b class="bold">any type</b>><b class="bold"> )</b>
When the arguments are of the STRING type, the value returned is the concatenation of the strings.
<b class="bold">BIT_AND( arg1 </b><<b class="bold">INTEGER</b>><b class="bold">, arg2 </b><<b class="bold">INTEGER</b>><b class="bold"> )</b><b class="bold">BIT_NOT( arg </b><<b class="bold">INTEGER</b>><b class="bold"> )</b><b class="bold">BIT_OR( arg1 </b><<b class="bold">INTEGER</b>><b class="bold">, arg2 </b><<b class="bold">INTEGER</b>><b class="bold"> )</b><b class="bold">BIT_SHL( arg1 </b><<b class="bold">INTEGER</b>><b class="bold">, arg2 </b><<b class="bold">INTEGER</b>><b class="bold"> )</b><b class="bold">BIT_SHR( arg1 </b><<b class="bold">INTEGER</b>><b class="bold">, arg2 </b><<b class="bold">INTEGER</b>><b class="bold"> )</b><b class="bold">BIT_XOR( arg1 </b><<b class="bold">INTEGER</b>><b class="bold">, arg2 </b><<b class="bold">INTEGER</b>><b class="bold"> )</b>
The BIT functions calculate the specified bitwise operators on the argument values.
<b class="bold">CASE </b><<b class="bold">field_expression</b>><b class="bold"> WHEN </b><<b class="bold">field_expression</b>><b class="bold"> THEN </b><<b class="bold">field_expression</b>><b class="bold"> [ ... ]</b><b class="bold"> [ ELSE </b><<b class="bold">field_expression</b>><b class="bold"> ]</b><b class="bold"> END</b>
The CASE function compares the value of the specified field-expression with the values of the field-expressions in the WHEN statements, returning the value of the field-expression specified in a THEN statement when a match is found. If no match...