This subsection describes regex functions that enable you to perform pattern matching. According to the BSON Specification, regular expressions are two-part values: They have a pattern and options. The functions listed below enable you separate these two parts and extract either of them (the regex-options and regex-pattern functions). You can also create a regex expression based on the pattern and options parameters (to-regex).
Important: The bson functions are compatible only with the Built-In transformation language.