All Products
Search
Document Center

Performance Testing:Placeholders

Last Updated:Nov 01, 2024

To create a query that can use different parameters each time it is executed, you can use placeholders in your query.

Procedure

If you use a placeholder in the SQL statement of a Java Database Connectivity (JDBC) performance testing request, you must configure the corresponding key and value on the Placeholder tab of the JDBC node.

  1. Configure basic request information for the JDBC node.

  2. Click the Placeholder tab and configure the parameters.

    Parameter

    Description

    Type

    The data type of the parameter.

    Value

    The value injected into the placeholder, represented by ? in the query.

Examples

The SQL statement of a JDBC node is select * from wp_users where user_status=?;.

The following placeholder settings are used:

image

The actual SQL statement executed is select * from wp_users where user_status=1;.