This command loads a character variable with all or part of the data from an HTTP response message body for a specified TCP connection. It is used after a GET, HEAD or POST command.
OpenSTA will automatically wait until any request on the specified connection ID is complete before executing this command. It is not necessary for the Script to do this explicitly.
If the data string is too long to fit into the target variable, it will be truncated. For a response message body containing an HTML document, the "WITH" clause may be used to load a character variable with an element or part of an element from the document.
The optional "RETURNING STATUS load_status" clause can be used to specify the integer variable to hold one of two values indicating whether the command succeeded or failed. There is an SCL include file "response_codes.inc" supplied with OpenSTA, which defines SCL integer constants for response status values. When "RETURNING STATUS" is specified, the "ON ERROR" action is disabled.
By default, if an error occurs, an error message is written in the audit log and the virtual user will continue. However, if error trapping is enabled, control will be transferred to the error-handling code.
LOAD RESPONSE_INFO BODY ON conid INTO variable {&} {,WITH identifier} {&} {,RETURNING STATUS load_status}
An integer variable, integer value or integer expression identifying the Connection ID of the TCP connection on which the HTTP response message will be received.
The name of a character variable into which the HTTP response message body, or the selected part of it, are loaded.
A character variable, quoted character string or character expression identifying the data to be retrieved from the response message body. For a definition of the identifier format see LOAD RESPONSE_INFO BODY Identifiers.
An integer variable into which the status of the load response_info execution is loaded.
LOAD RESPONSE_INFO BODY ON 1 INTO post_body