How to use all captured dynamic values in next request

35 Views Asked by At

I have 2 requests Claims and update claims, for a user if I get 5 claims I need to run all the claims in the next request submitting all the claim values.

Claims=234,456,789,876,987 The above values are captured using regular expression extractor. I need to run next request no of times we have claims for a user, So I'm using loop controller with match NR number loop counter. Under loop counter I have a next request where I need to process all claims Next request where claims are passed. I'm using counter to increment the captured value number and pass all claims Counter used.

But this method is not working to pass all the claims when I use counter.

I have tried Counter to use all the claims but it was not working.

When used this Hardcoded number it was working and same claim is processing loop number of times.

1

There are 1 best solutions below

1
Dmitri T On

If you have the following JMeter Variables defined (you can see all created variables along with their respective values using Debug Sampler and View Results Tree listener combination)

Claims_1=234
Claims_2=456
...
Claims_MatchNr=xxx

and would like:

  • 1st request to use 234
  • 2nd request to use 456
  • etc

The correct syntax to refer the "next" variable under the loop would be ${__V(Claims_${count},)}

Check out __V() function documentation for more information