Skip Headers

Oracle Call Interface Programmer's Guide
Release 2 (9.2)

Part Number A96584-01
Go To Documentation Library
Home
Go To Product List
Book List
Go To Table Of Contents
Contents
Go To Index
Index

Master Index

Feedback

Go to previous page Go to beginning of chapter Go to next page

OCI Any Type and Data Functions, 20 of 26


OCIAnyDataSetAddInstance()

Purpose

Adds a new skeleton instance to the OCIAnyDataSet and all the attributes of the instance are set to NULL.

Syntax

sword OCIAnyDataSetAddInstance ( OCISvcCtx      *svchp, 
                                 OCIError       *errhp, 
                                 OCIAnyDataSet  *data_set, 
                                 OCIAnyData     **data );

Parameters

svchp (IN)

The OCI service context.

errhp (IN/OUT)

The OCI error handle. If there is an error, it is recorded in err and this function returns OCI_ERROR. Obtain diagnostic information by calling OCIErrorGet().

data_set (IN/OUT)

OCIAnyDataSet to which a new instance is added.

data (IN/OUT)

OCIAnyData corresponding to the newly added instance. If (*data) is NULL, a new OCIAnyData will be allocated for the same duration as the OCIAnyDataSet. If (*data) is not NULL, it will be reused. This OCIAnyData can be subsequently constructed using the OCIAnyDataConvert() call or it can be constructed piece-wise using the OCIAnyDataAttrSet() or the OCIAnyDataCollAddElem() calls.

Comments

This call returns this skeleton instance through the OCIAnyData parameter which can be constructed subsequently by invoking the OCIAnyData API.


Note:

No destruction of the old value is done here. It is your responsibility to destroy the old value pointed to by (*data) and set (*data) to a NULL pointer before beginning to make a sequence of these calls. No deep copying (of OCIType information or of the data part) is done in the returned OCIAnyData. This OCIAnyData cannot be used beyond the allocation duration of the OCIAnyDataSet (it is like a reference into the OCIAnyDataSet). The returned OCIAnyData can be reused on subsequent calls to this function, to sequentially add new data instances to the OCIAnyDataSet.



Go to previous page Go to beginning of chapter Go to next page
Oracle
Copyright © 1996, 2002 Oracle Corporation.

All Rights Reserved.
Go To Documentation Library
Home
Go To Product List
Book List
Go To Table Of Contents
Contents
Go To Index
Index

Master Index

Feedback