Every performance testers must know about how to correlate, no matter which tool they are using. Correlation is nothing but capturing the dynamic data (response) from the server and send the captured response to the subsequent requests.
To capture the dynamic data from the server, in LoadRunner we use web_reg_save_param function. In web_reg_save_param function, we use following parameters: Left boundary, Right boundary, Ord, SaveLen etc.
E.g. consider below is the dynamic data from the server which has the LB and RB as <span class=”login-bold”> and </span> respectively.
[stextbox id=”grey”]<span class=”login-bold”>@[email protected]$39945ksjklsg</span>[/stextbox]
In above case, we can easily capture the dynamic data and pass it to subsequent requests. But what if the left and right boundaries changes dynamically? How to handle dynamic boundaries? In this article, we are going to see about how to correlate dynamic boundaries in LoadRunner.
E.g. consider the below response from the server which has the dynamic boundaries.
The left and right boundaries are OrderID1234, OrderID3456, OrderID8798 and 1234, 3456, and 8798 respectively. The dynamic data is dynamicresponsedata
To capture the dynamicresponsedata by using left and right boundaries (of course that is also dynamic in nature), use below syntax:
web_reg_save_param(“Correlation_1”, “LB/DIG= OrderID####\=”, “RB=####”, LAST);
you need to enter DIG to interpret # (hash) tag where you expect digit. You can use IC flag i.e. ignore case flag in your function as shown below. Apart from IC, DIG, you can also use ALNUM (alpha numeric), to specify binary data, use /BIN
web_reg_save_param(“Correlation_2”, “LB/IC/DIG= OrderID####\=”, “RB/IC=####”, LAST);
If the left and right boundaries has dynamic string e.g. four letter user name, you use below syntax.
web_reg_save_param(“Correlation_3”, “LB/IC/DIG= OrderID^^^^\=”, “RB/IC=^^^^”, LAST);
- #3 – LoadSter, Google Chrome, and Sonarwhal – QAInsights Podcast - April 25, 2018
- #2 QAInsights Podcast – 126.96.36.199 and many more - April 9, 2018
- QAInsights Podcasts – First Episode - March 30, 2018
- Rajini Makkal Mandram Vs Makkal Neethi Maiyam – a tech comparison - March 5, 2018
- Do not blame it on server! - February 26, 2018