Log on to OceanBase Developer Center (ODC) and click the name of the target connection to go to the corresponding connection management page. You can click Stored Procedure in the left-side navigation pane to get a list of stored procedures. To create a stored procedure, click + in the upper-right of the stored procedure list or click Create in the navigation bar on the top of the page. The following table describes the parameters that you need to specify to create a stored procedure.
| Parameter | Description |
|---|---|
| Stored ProcedureName | Specifies the name of the stored procedure. |
| Parameter | Specifies the information passed to the stored procedure when the stored procedure is called. You must specify Name , Mode , Data Type , and Default Value for a parameter. The Default Value setting is unavailable in MySQL mode. You can drag the parameters to reorder them. |
You need to specify Mode for a parameter to indicate its type. The following parameter modes are supported: IN , OUT , and INOUT .
IN : indicates an input parameter. When a stored procedure is called, the input parameter is passed to the stored procedure and used in the execution of the stored procedure.
OUT : indicates an output parameter. When a stored procedure is called, the value of an output parameter is ignored and an empty value is passed to the stored procedure. The value of the output parameter is modified during the execution of the stored procedure. After the execution is completed, the modified value is assigned to output parameter. Usually, output parameters are used to obtain the execution results of a stored procedure.
INOUT : indicates an inout parameter. An inout parameter has the features of both an input parameter and an output parameter.
