Skip to content

__V

JMeter __V 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.

TL;DR: __V (Variable evaluation) resolves a dynamically built variable name โ€” e.g. ${__V(row_${__counter(FALSE,)})} reads row_1, row_2, โ€ฆ โ€” solving the โ€œvariable name thatโ€™s itself made of variablesโ€ problem that plain ${...} substitution canโ€™t handle in one step.

The V (variable) function returns the result of evaluating a variable name expression. This can be used to evaluate nested variable references (which are not currently supported).

For example, if one has variables A1,A2 and N=1:

  • \${A1} - works OK
  • \${A\${N}} - does not work (nested variable reference)
  • \${__V(A\${N})} - works OK. A\${N} becomes A1, and the __V function returns the value of A1
NameRequiredDescription
Variable nameYesThe variable to be evaluated.
Default valueNoThe default value in case no variable found, if itโ€™s empty and no variable found function returns the variable name
${__V(row_${__counter(FALSE,)})} โ†’ resolves to the value of row_1, row_2, ... as the counter increments

This pattern shows up whenever youโ€™ve extracted multiple values with Match No. = -1 (producing var_1, var_2, โ€ฆ) and need to loop through them by a computed index โ€” see __eval for the related โ€œevaluate this string as an expressionโ€ function.

On this page