Search code examples
jmeterbeanshelljmeter-3.2

How to extract value without any condition in Regular Expression Jmeter?


Using Bean Shell Sampler, I am getting response data as

"tjH9/c05vDE3/Bg2R/fqyR5W7MR31GUmqLb/it36smrsPq4xvM6MhfqP5haE9nzSnzm7+vUXdeKiXzygKtAW4CgEk29c/m8hSvl5isHeFca+V35/AMMKAvjvXq6gbSL5k0ujIymbmnJ2rUgIOHEm6K5YgvJ0ZWAoHcW+Tsk7HqgSYQGz5EBVGsoYVbbd0l/TZEVlbMPYSuKKcEV6ykja8lgmt8Llww9qbgTKwVU6eNVqW7PSjkllJvJtj+j5swbMSZ7/Huisg/deGMo/NlSKnFK1Ym8QTv5agxgKlxWTNboccNoqvgzCOEfn/wG84moKpZiAH4cLagt3kyWVJaix4A==" 

Note: The above response data is not in Json. I need to extract the same data as is ( above mentioned) using Regular expression / any other expression to pass the same to the subsequent request.

Is it Possible?


Solution

  • If you want to extract everything from the parent sampler response you can use the following Regular Expression:

    (?s)(^.*)
    

    Explanation:

    • () = grouping

    • (?s) = single line modifier

    • ^ = line start

    • . = wild-card character

    • * = repetition

    More information: