Re: Timestamps (357 Views)
Reply
Occasional Advisor
subrat_perf
Posts: 21
Registered: ‎02-03-2012
Message 1 of 6 (426 Views)

Timestamps

Hi,

 

I am  getting so many random numbers in my script as below.

 

web_submit_data("Mywebpage.do_6", 
        "Action={Enviornment}/pc/Mywebpage.do?ts=19355093", 
        "Method=POST", 
        "RecContentType=text/html", 
        "Referer={Enviornment}/pc/Mywebpage.do?ts=98991789", 
        "Snapshot=t9.inf", 
        "Mode=HTML", 
        ITEMDATA, 
        "Name=TabBar:PolicyTab:PolicyTab_SubmissionNumberSearchItem", "Value=", ENDITEM,

 

I am not sure but I think these are timestamps(bcoz of 'ts') and there are so many different values throughout the script.

The script is working fine with these original recorded values .

 

My question is do I need to correalte or make these values dynamically appear by any other means?

 

Occasional Advisor
Satzz
Posts: 12
Registered: ‎09-24-2012
Message 2 of 6 (416 Views)

Re: Timestamps

Hi,

 

Pls check with generation log whether its related to time .Also, make sure that, only last 3 or 4 digits only changes  in the timestamp number. if each number is different, then its not a timestamp. If you are sure it is a timestamp , you can use web_save_timestamp_param function before each hits where timestamp value occurs.

 

Thanks

Occasional Advisor
subrat_perf
Posts: 21
Registered: ‎02-03-2012
Message 3 of 6 (395 Views)

Re: Timestamps

Thnks for the response.

 

Here all digits are different and not only the last four.So we cannot use 'web_save_timestamp_param()'

 

I was considering it as something like time stamp because of the word 'ts' before it,

 

The script is working fine without correlating it or even when i am deleting this number.

But as a general practice we should get rid of any kind of dynamic values from script.

 

So is correlation the only solution or there is any other means to make it dynamically appear?

 

 

Regular Advisor
LoadRunner421
Posts: 79
Registered: ‎02-20-2013
Message 4 of 6 (389 Views)

Re: Timestamps

[ Edited ]

        "Action={Enviornment}/pc/Mywebpage.do?ts=19355093", 
        "Referer={Enviornment}/pc/Mywebpage.do?ts=98991789",

 

 

What are those numbers used for in the application? 

 

Once you know what the numbers are used for then you will know if you need to correlate them or not. So instead of playing a  guessing game why not just go and get the information? (Ask the developers)

Valued Contributor
Nathan Bramble
Posts: 51
Registered: ‎02-22-2011
Message 5 of 6 (382 Views)

Re: Timestamps

What you have in your sample code is a typical way web based applications pass variables from page to page, but LoadRunner is only telling you that the page you requested was present. So "ts" is the variable throughout your application being tested and each of the numbers are the values being used on those pages. Your developers should be able to explain how they are used. If they're dynamic you'll need to correllate them.
You can't trust LR to send back any errors or failures for invalid URL variables unless you have error checking in the script code. Since Mywebpage.do is a file and does respond to a request to that file LR will report it as success. The page may be working as you expect or just be one big error message, but unless your script is specifically looking for a valid response you won't know.

Trusted Contributor
Oded_Keret
Posts: 107
Registered: ‎08-13-2011
Message 6 of 6 (357 Views)

Re: Timestamps

I agree with LoadRunner421 - just ask the developers.

Sometimes timestamps may represent the current time declared by the browser, and other times they may represent an event that occured on the server side.

So using LR API to save the current timestamp will not always be the correct behavior.

Oded Keret
The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation.