ODBC Server Reference Manual

Stored Procedures
HP NonStop ODBC Server Reference Manual429151-002
5-2
Overview of Stored Procedures
2. Invocation of the stored procedure DEBIT_ACCOUNT:
execute DEBIT_ACCOUNT ("John Smith", 50.00)
Overview of Stored Procedures
The NonStop ODBC Server allows the user to develop stored procedures in a familiar
3GL language, such as C or COBOL. Using a 3GL language provides the user with full
access to all of the capabilities of the 3GL language, along with the performance and
debugging features that come with this approach. In addition, the NonStop ODBC
Server uses Pathway to manage the stored procedures, which provides for efficient
load balancing and server class management.
Stored procedures can be used in two ways:
One way involves “light” use: the procedures are created and used by the same
user, they are modified often, performance is not critical, and they may have a
short life cycle.
The other way is “heavy” use: the procedures are created and changed
infrequently, they are shared by several users, and their performance is important.
NonStop ODBC Server support of stored procedure execution is most appropriate
for this second use.
Stored procedures can be written in either the C programming language or COBOL85.
How Stored Procedure Execution Works
Figure 5-1 illustrates how the NonStop ODBC server accepts a stored procedure
invocation statement, submits it to a Pathway server class program, and returns results
to the client application.
1. An application issues an ODBC or DBLIB call that sends a stored procedure
invocation statement to the NonStop ODBC server.
Figure 5-1. Executing Stored Procedures
Application
NonStop ODBC
Mapping
Tables
45
NonStop
SQL/MP
Objects
NonStop ODBC
Server
1 2
3
Pathway
Server Class
VST040.vsd