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

mi_collection_open_with_options()

The mi_collection_open_with_options() function opens a collection in a specified open mode.

Syntax

Usage

The mi_collection_open_with_options() function is a constructor function for the collection descriptor. It opens the collection that the coll_struc argument references and returns a collection descriptor to this open collection. Other DataBlade API collection functions use this collection descriptor to access the elements of a collection.

The mi_collection_open_with_options() function allocates a new collection descriptor in the current memory duration.

This function is useful for accessing collection subqueries.

This function creates a collection cursor to hold the collection elements. By default, this cursor is an update scroll cursor. If this type of cursor is not adequate for your DataBlade API module, you can create a collection cursor with characteristics specified by a bit mask in the control argument.

Collection Cursor Type Control-Flag Value
Update scroll cursor None (default)
Read-only scroll cursor MI_COLL_READONLY
Update sequential cursor MI_COLL_NOSCROLL
Read-only sequential cursor MI_COLL_READONLY + MI_COLL_NOSCROLL

Return Values

MI_COLL_DESC * is the address of the collection descriptor for the opened collection.
NULL indicates that the function was not successful.

Related Topics

See the descriptions of the following functions: mi_collection_close(), mi_collection_copy(), mi_collection_create(), mi_collection_delete(), mi_collection_fetch(), mi_collection_free(), mi_collection_insert(), mi_collection_open(), and mi_collection_update().


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