Skip to content

__escapeOroRegexpChars

JMeter __escapeOroRegexpChars function reference: syntax, parameters, and practical examples for parameterizing test plans with dynamic values.

Difficulty
intermediate
Guide type
reference
Estimated read time
1 min read
Last verified version
Verified JMeter 5.6

Also documented in context in the full Functions and Variables reference.

Function which escapes the ORO Regexp meta characters, it is the equivalent of \Q \E in Java Regexp Engine.

For example,

Terminal window
\${__escapeOroRegexpChars([^"].+?,)}

returns: \[\^\"\]\.\+\?.

Uses Perl5Compiler#quotemeta(String) from ORO.

NameRequiredDescription
String to escapeYesThe string to be escaped.
Variable NameNoA reference name - refName - for reusing the value created by this function. Stored values are of the form \${refName}.
On this page