Data Connection and Preparation > Structuring Data Sets > Creating Other Objects > Data Handler in DBMS > Procedure
The Procedure object enables the user to create procedures and functions for various DBMS.
Unlike the DBMS command, a stored procedure or function is created on the server when the Procedure object is created in the repository. Several repository procedures may refer to the same stored procedure on database server. Changes in text of a stored procedure affect all objects referring to this procedure. The result of a procedure is the number of processed records, or some specific value if a function is created instead of a procedure.
NOTE. Creating of procedures and functions is unavailable in SQLite DBMS because such object type is missing in this DBMS.
To create the Procedure object in the object navigator:
In the web application click the Create button in the main menu and select the object type on the New Object side panel.
In the desktop application:
Select the Create > Other > Procedure context menu item.
Select the New Object > Other > Procedure item in the Create group on the Home ribbon tab.
After executing one of the operations, the procedure creation wizard opens containing the pages:
Basic Settings/Basic Properties. It is used to set object name, identifier and comment.
Parameters. The list of parameters, which will be used in the procedure code, is set. A role in procedure code is defined for each parameter.
Procedure/Function. It sets up the procedure, determines its type and executed script.
To save settings in the procedure wizard:
In the web application:
Click the Save button.
Select the Save and Close item in the drop-down menu of the Save button. After this the specified settings are saved, the wizard closes, and the data edit mode opens.
NOTE. The Save and Close item is available only on editing the settings.
In the desktop application click the Finish button.
To open a procedure for edit, select the corresponding object in the object navigator and execute one of the operations:
Select the Edit item in the procedure's context menu.
Select the Edit in a New Tab item in the procedure's context menu.
Select the Edit in a New Window item in the procedure's context menu.
Press F4.
The procedure editing dialog box opens:
Available operations:
Change procedure/function text
See also:
Example of Creating a Procedure| Data Handlers in DBMS | IProcedure