JDBC template inputs

You use the Inputs tab to create variables to pass into the activity or to initiate variable auto-mapping.

You can test the JDBC connection between the MID Server and the target database without having to run the acvitity in a workflow context. For details, see Test JDBC activity template inputs.
Note: Variable strings in the Inputs tab have a 255 character limit.
Figure 1. JDBC activity Inputs tab
Table 1. JDBC input fields
Field Description
Input Input variable builder. Create variables to map to available fields.
Note: The auto-mapping feature provides the variables when enabled.
Data source Appropriate JDBC data source. The data source must be a JDBC type. The data source selected provides the activity with the following information:
  • JDBC user name
  • Target database server IP address or valid URL
  • Target database name
  • Target database port (if different from standard port number)
  • JDBC password
  • MID Server name
SQL statement Customer provided SQL statement. This SQL statement is used rather than the statement from the JDBC data source. This field is hidden when the Stored Procedure check box is selected.

The operations that the JDBCOrchestrationProbe can execute are controlled by the mid.property.jdbc_operations MID Server property.

This activity can run the following SQL statements:
  • select
  • insert
  • update
  • delete
Note: You cannot run multiple statements of different types. For example, you cannot run a select statement and an update statement together, but you can run two insert statements. However, you cannot run multiple select statements in this activity.
Auto-map to Automatically maps the entire payload to selected variables. The choices in this field are:
  • None
  • Local Variable: Translates the entire payload into a JSON object and places it in the data bus. This allows for post-processing manipulation in JavaScript. This selection causes the entire data field on the right to disappear and the inputs structure to be autopopulated with these default variables:
    • output
    • totalRows
    • errorMessage
    • eccSysId
  • Output Variable: Automatically populates the output variables in the activity with the same default variables used as inputs for the local variable.
Note: No parsing rules are available with auto-mapping selections.
Maximum rows Maximum number of records to retrieve from database.
Connection timeout How long the activity waits to make the connection. This field is populated automatically from the data source, but can be changed for this activity.
Query timeout Elapsed time to wait after running the query until the data is returned. This field is populated automatically from the data source, but can be changed for this activity.
Use stored procedure Selects whether to use a stored procedure that contains preconfigured input parameters. When this check box is selected, the system hides the SQL statement field and displays the Stored procedure name and Stored procedure parameter fields.
Stored procedure name Name of your stored procedure. The system populates the input parameters using values from this stored procedure. This field is displayed when the Use stored procedure check box is selected.
Note: Stored procedures can only execute select statements.
Stored procedure parameters Parameters from the selected stored procedure. Add the parameter values you want for each type.
  • Mode: Parameter type.
  • SQL Type: Data type of the parameter.
  • Name: Parameter name.
  • Value: Value you want passed to the parameter.
JDBC activity stored procedure