All values of rule parameters or AD fields can be casted by substring operation. The substring will return part of original value specified by start and length parameters.
The syntax of substring is: input value (Start, Length)
Input value – rule parameter or AD field
Start - is non-negative, the returned value will start at the this position in string, counting from one.
Length – length or returned value