You are on page 1of 4

Co-relation in Siebel

Types of Co-relation
y Simple Variable Co-relation

In the following example, VuGen detected the _sn boundary. It saved the parameter to Siebel_sn_cookie6 and used it in the web_url function. /* Registering parameter(s) from source web_reg_save_param("Siebel_sn_cookie6", "LB/IC=_sn=", "RB/IC=;", "Ord=1", "Search=headers", "RelFrameId=1", LAST); ... web_url("start.swe_3", "URL=http://cannon.hplab.com/callcenter_enu/start.swe?SWECmd=GotoPostedAction&SWEDIC=tr ue&_sn={Siebel_sn_cookie6}&SWEC={Siebel_SWECount}&SWEFrame=top._sweclient&SWECS=true ", "TargetFrame=", "Resource=0", "RecContentType=text/html", "Referer=http://cannon.hplab.com/callcenter_enu/start.swe?SWECmd=GetCachedFrame&_sn={Sie bel_sn_cookie6}&SWEC={Siebel_SWECount}&SWEFrame=top._swe", "Snapshot=t4.inf", "Mode=HTML", LAST);

Functional Co-relation

In certain instances, the boundary match is a function. Functions generally use an array to store the run-time values. In order to correlate these values, VuGen parses the array and saves each argument to a separate parameter using the following format: <parameter_name> = <recorded_value> (display_name) The display name is the text that appears next to the value, in the Siebel Application. VuGen inserts a comment block with all of the parameter definitions.

/* Registering parameter(s) from source task id 159 // {Siebel_Star_Array_Op33_7} = "" // {Siebel_Star_Array_Op33_6} = "1-231" // {Siebel_Star_Array_Op33_2} = "" // {Siebel_Star_Array_Op33_8} = "Opportunity" // {Siebel_Star_Array_Op33_5} = "06/26/2003 19:55:23" // {Siebel_Star_Array_Op33_4} = "06/26/2003 19:55:23" // {Siebel_Star_Array_Op33_3} = "" // {Siebel_Star_Array_Op33_1} = "test camp" // {Siebel_Star_Array_Op33_9} = "" // {Siebel_Star_Array_Op33_rowid} = "1-6F" // */ In addition, when encountering a function, VuGen generates a new parameter for web_reg_save_param, AutoCorrelationFunction. VuGen also determines the prefix of the parameters and uses it as the parameter name. In the following example, the prefix is Siebel_Star_Array_Op33. web_reg_save_param("Siebel_Star_Array_Op33", "LB/IC=`v`", "RB/IC=`", "Ord=1", "Search=Body", "RelFrameId=1", "AutoCorrelationFunction=flCorrelationCallbackParseStarArray", LAST); VuGen uses the parameters at a later point within the script. In the following example, the parameter is called in web_submit_data. web_submit_data("start.swe_14", "Action=http://cannon.hplab.com/callcenter_enu/start.swe", "Method=POST", "RecContentType=text/html", "Referer=", "Snapshot=t15.inf", "Mode=HTML", ITEMDATA, "Name=SWECLK", "Value=1", ENDITEM, "Name=SWEField", "Value=s_2_1_13_0", ENDITEM, "Name=SWER", "Value=0", ENDITEM, "Name=SWESP", "Value=false", ENDITEM,

"Name=s_2_2_29_0", "Value={Siebel_Star_Array_Op33_1}", ENDITEM, "Name=s_2_2_30_0", "Value={Siebel_Star_Array_Op33_2}", ENDITEM, "Name=s_2_2_36_0", "Value={Siebel_Star_Array_Op33_3}", ENDITEM, ... During replay, Vusers do a callback to the public function, using the array elements that were saved as parameters.

SWEC Co-relation

SWEC is a parameter used by Siebel servers representing the number of user clicks. The SWEC parameter usually appears as an argument of a URL or a POST statement. For example: GET /callcenter_enu/start.swe?SWECmd=GetCachedFrame&_sn=2mOTFXHWBAAGb5Xzv9Ls2Z45QvxGQnOnPVtX6vnfUU_&SWEC=1&SWEFrame=top._swe._sweapp HTTP/1.1 or POST /callcenter_enu/start.swe HTTP/1.1 ... \r\n\r\n SWERPC=1&SWEC=0&_sn=2mOTFXHWBAAGb5Xzv9Ls2Z45QvxGQnOnPVtX6vnfUU_&SWECmd=InvokeMethod... VuGen handles the changes of the SWEC by incrementing a counter before each relevant step. VuGen stores the current value of the SWEC in a separate variable (Siebel_SWECount_var). Before each step, VuGen saves the counter's value to a VuGen parameter (Siebel_SWECount). In the following example, web_submit_data uses the dynamic value of the SWEC parameter, Siebel_SWECount. Siebel_SWECount_var += 1; lr_save_int(Siebel_SWECount_var, "Siebel_SWECount"); web_submit_data("start.swe_8", "Action=http://cannon.hplab.com/callcenter_enu/start.swe", "Method=POST", "TargetFrame=", "RecContentType=text/html", "Referer=", "Snapshot=t9.inf", "Mode=HTML", "EncodeAtSign=YES",

ITEMDATA, "Name=SWERPC", "Value=1", ENDITEM, "Name=SWEC", "Value={Siebel_SWECount}", ENDITEM, "Name=SWECmd", "Value=InvokeMethod", ENDITEM, "Name=SWEService", "Value=SWE Command Manager", ENDITEM, "Name=SWEMethod", "Value=BatchCanInvoke", ENDITEM, "Name=SWEIPS",... LAST);

SWET Co-relation

web_save_timestamp_param: This function saves the current timestamp to LoadRunner parameter. Timestamp is the number of milliseconds since midnight January 1st, 1970 (also known as Unix Epoch). VuGen replaces all non-empty timestamps in the script, with the parameter {SiebelTimeStamp}. Before saving a value to this parameter, VuGen generates the following function: web_save_timestamp_param("SiebelTimeStamp", LAST); This function saves the current timestamp to the SiebelTimeStamp parameter. Return values: This function returns LR_PASS (0) on success, and LR_FAIL (1) on failure. Parameterization: Not applicable Example: web_save_timestamp_param("tStamp", LAST );

You might also like