Run stored procedure
Call a stored procedure or function with input, output and in-out parameters; return the rows it produces, its output values and a function's return value.
Command in the Database toolkit · id ooa.database/call_procedure · 7 inputs (1 required), 4 outputs
Inputs
| Input | Type | Required | Default | What it is |
|---|---|---|---|---|
| Procedure | String | Yes | Procedure name, optionally schema.name. | |
| Parameters | List | No | Parameters in the procedure's order: a plain value is an input; {"value": v, "direction": "out" or "inout", "type": "varchar|integer|bigint|decimal|double|boolean|date|timestamp", "name": "p_total"} declares an output. | |
| Maximum rows | Number | No | 100000 | Safety limit on rows returned. |
| Session | String | No | db | Session name. |
| Query timeout (seconds) | Number | No | 0 | Cancel the statement after this many seconds; 0 waits as long as the step allows. |
| Returns value | Boolean | No | false | Call it as a function ({? = call ...}) and return its value as out_parameters.return. |
| Return type | String | No | SQL type of the function's value; varchar when empty. |
Outputs
| Output | Type | What it is |
|---|---|---|
| table | Table | First result set, or an empty table. |
| row_count | Number | Rows in the result table. |
| rows_affected | Number | Rows changed, when the database reports it; otherwise -1. |
| out_parameters | Dictionary | Output and in-out values by parameter name (or position 1, 2 ... when unnamed); the function's value as "return". |