Stproc.close()

NES3+Syntax

							stproc.close()

Description

The close() method of the Stproc object closes the stored procedure and frees all memory used to store its information. If successful, the method returns 0; otherwise, it returns an error code that can be obtained by using the majorErrorCode() and majorErrorMessage() methods of the Connection or database objects.

Example

Listing 8.143 creates a stored procedure and then closes it.

Listing 8.143 Closing a Cursor with the close() Method
 <SERVER> // Open a connection var myConn = database.connect("ORACLE", "mySID", "myApp", "appsPWD", "myTNS"); myConn.beginTransaction(); // Run the stored procedure var myStproc = myConn.storedProc("sp_employees"); // Store the result set var myResultSet ...

Get Pure JavaScript now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.