OdxIsOpened
OdxIsOpened checks to see if a cursor is valid.
Syntax
OdxIsOpened @cursor
@cursor integer
The cursor number to be checked
Options
Example
This example checks to see if the passed cursor is open and closes it
if it is. It then checkes to see if the passed instance number is connected
and closes it if it is.
CREATE PROCEDURE prODXDisconnect
@cursor_num int,
@instance_num int
AS
declare @status int
exec @status = master.dbo.odx_is_opened @cursor_num
if @status <> 0
exec @status = master.dbo.odx_close_cursor @cursor_num
exec @status = master.dbo.odx_is_connected @instance_num
if @status <> 0
exec @status = master.dbo.odx_disconnect_env @instance_num
GO
Top
|