informix
Informix DataBlade API Programmer's Manual
DataBlade API Function Descriptions

mi_get_connection_option()

The mi_get_connection_option() function returns information about the database of the current connection.

Syntax

Usage

The mi_get_connection_option() function puts information about the connection attribute that conn specifies in the location that result_ptr references.

The following table lists the valid values for conn_option and the associated possible values that result_ptr references.

Description Connection-Option Constant Result
Is the open database an ANSI-compliant database? MI_IS_ANSI_DB MI_TRUE or MI_FALSE
Does the open database use a transaction log? MI_IS_LOGGED_DB MI_TRUE or MI_FALSE
Is the database in exclusive mode? (Has the DATABASE statement included the EXCLUSIVE keyword?) MI_IS_EXCLUSIVE_DB MI_TRUE or MI_FALSE

This function copies this value into the buffer that result_ptr references. The function allocates memory for the result in the current memory duration. When you no longer need this result, free this memory.

Return Values

MI_OK indicates that the function was successful.
MI_ERROR indicates that the function was not successful.

The mi_get_connection_option() function raises an exception for the following conditions:


Informix DataBlade API Programmer's Manual, Version 9.2
Copyright © 1999, Informix Software, Inc. All rights reserved