Forum Discussion

axedesign's avatar
New Contributor
10 years ago

Why data modifiers is not modifing parameters in reqest

I'm new to LoadComplete. I'm fighting with load test preparation and I've stuck with data modifiers. I read the documentation and tried figure it out but I need someone to help me to show where I'm making mistake.


I have request-response-request chain:



<?xml version="1.0" encoding="UTF-8"?>
<serviceResponse returnLength="2">
<output name="mainCaseId"><variable type="String"><![CDATA[76209]]></variable> </output>
<output name="error"><variable /> </output>


I did a correlation in Parameters tab and assigned value 76209 to a variable vMainCaseId.


Now I want to populate value 76209 into succeeding request (below)


GET /portal/jsp/ HTTP/1.1


I need to put 76209 instead of 99999 (highlighted)


I tried Data Modifiers tab:

%3E(\d{3,})%3C --> vMainCaseId

mainCaseId%22%3E\K(\d{3,}) --> vMainCaseId


and few more but no luck. 


How should it be done corectly?


How can I debug what and see what values are actualy catched into variables?


Thanks in advance for any hints.




3 Replies

    • axedesign's avatar
      New Contributor

      Hi Ryan,


      Thanks for feedback.

      I did try both methods you offer and put variable into the request but no luck at all.


      Documentation about parametrisation of URLs says that:

       "Variables followed by characters other than the separators /, ? and &. Semicolons (;) are not separators"

      and the problem here is that the value I want to replace is not followed by any of above separators.


      GET /portal/jsp/ HTTP/1.1




      Any clue?




  • AlexKaras's avatar
    Champion Level 3

    Hi Olaf,


    First (this will be referenced below), decoded value for the request is:

    GET /portal/jsp/<input name="elementValue"><variable name="mainCaseId">99999</variable></input> HTTP/1.1



    I would try the following:

    -- It is my guess that you are using Data Selector to get the value of mainCaseId into the vMainCaseId variable;

    -- Assume, that the regexp for this Data Selector is '<!\[CDATA\[(\d{3,})\]\]>';

    -- Now, try to put something like this into the Subexpression field for this DataSelector:

    <input name="elementValue"><variable name="mainCaseId">$1</variable></input>

    I.e., you will assign to the vMainCaseId variable not just case id, but the whole value of the 'input' URL parameter;

    -- And finally, assign the following for the subsequent request:

    GET /portal/jsp/ HTTP/1.1


    Does this work?