Hi,

>From https://jmeter.apache.org/usermanual/functions.html#__evalVar

__evalVar
>
> The evalVar function returns the result of evaluating an expression stored
> in a variable.
>
> This allows one to read a string from a file, and process any variable
> references in it. For example, if the variable "query" contains "select
> ${column} from ${table}" and "column" and "table" contain "name" and "
> customers", then ${__evalVar(query)} will evaluate as "select name from
> customers".
>

However, I tried it (in JM5.5), but wasn't able to make it work:

query = '''select ${column} from ${table}'''
column = "name"
table = "customers"

log.info("${query}")
log.info('=${__evalVar(query)}=')


but the output I got is:

select ${column} from ${table}==
How to make it work please?

Reply via email to