I have a jmeter thread group which uses transaction controller & a while loop controller inside that to run a query to fetch a token from db. while loop controller has below condition - ${__javaScript("${db_data}".indexOf("replay") == -1,)}
This variable db_data is retrieved with a select query result & loop will run until a value is there (inserted with a http request at the start of thread group). My issue is that until loop count in the thread group is 1; it works fine but once loop count is 2 or more, 2nd iteration is breaking the while loop instantly. How can I ensure that each thread loop initiates with variable db_data as null & does not retain the value inserted in previous run?