Nonstop Database, HiRDB Version 9 Description
The following is the general procedure for creating and executing an external C stored routine:
For details about executing external C stored routines, see the HiRDB Version 9 UAP Development Guide.
The following figure shows the flow of events from creation of an external C stored routine to its execution.
Figure 5-6 Flow from creation to execution of an external C stored routine
In this step, you code either a procedure or a function in C, and then you compile the resulting C program. Compilation produces an object file. You then link multiple object files to create a C library file.
In this step, you register the new C library file in HiRDB.
You use the CREATE PROCEDURE or CREATE FUNCTION statement to define an external C stored routine.
As in the case of executing a stored procedure or a stored function, you execute the SQL by specifying either a CALL statement or a function call. The CALL statement causes a C function to be executed as a C stored procedure. The function call causes a C function to be executed as a C stored function.
All Rights Reserved. Copyright (C) 2015, Hitachi, Ltd.