Oracle Call Interface Programmer's Guide Release 2 (9.2) Part Number A96584-01 |
|
This chapter describes the OCI navigational functions which are used to navigate through objects retrieved from an Oracle database server. It also contains the descriptions of the functions which are used to obtain type descriptor objects (TDOs).
See Also:
For code examples, see the demonstration programs included with your Oracle installation. For additional information, refer to Appendix B, "OCI Demonstration Programs". |
The chapter contains the following sections:
In an object navigational paradigm, data is represented as a graph of objects connected by references. Objects in the graph are reached by following the references. The OCI provides a navigational interface to objects in the Oracle server. Those calls are described in this chapter.
The OCI object environment is initialized when the application calls OCIInitialize()
in OCI_OBJECT mode.
See Also:
For more information about using the calls in this chapter, refer to Chapter 10, "OCI Object-Relational Programming", and Chapter 13, "Object Cache Navigation". |
An object instance is an occurrence of a type defined in an Oracle database. This section describes how an object instance can be represented in OCI. See Figure 17-1. In OCI, an object instance can be classified based on the type, the lifetime and referenceability:
A value can be standalone or embedded. A standalone value is usually obtained by issuing a select statement. OCI also allows the client program to select a row of object table into a value by issuing a SQL statement. A referenceable object in the database can be represented as a value which cannot be identified by a reference. A standalone value can also be an out-of-line attribute in an object, such as VARCHAR
or RAW
, or an out-of-line element in a collection, such as VARCHAR
, RAW
, or object.
An embedded value is physically included in a containing instance. An embedded value can be an in-line attribute in an object. such as number or nested object, or an in-line element in a collection.
All values are considered to be transient by OCI, which means that OCI does not support automatic flushing a value to the database, and the client has to explicitly execute a SQL statement to store a value into the database. For embedded values, they are flushed when their containing instance are flushed.
Figure 17-1 shows how instances can be classified according to their type and lifetime:
The distinction between various instances is further illustrated by the following table:
In the remainder of this chapter, the following terms will be used:
See Also:
For a further discussion of the terms used to refer to different types of objects, please see "Persistent Objects, Transient Objects, and Values". |
The entries for each function contain the following information:
A brief description of what the function does.
The function declaration.
Detailed information about the function if available. This may include restrictions on the use of the function, or other information that might be useful when using the function in an application.
A description of each of the function's parameters. This includes the parameter's mode. The mode of a parameter has three possible values, as described below:
A description of what value is returned by the function if the function returns something other than the standard return codes listed in Table 18-1, "Function Return Values".
A list of related calls which may provide additional useful information.
The OCI navigational functions typically return one of the following values:
Function-specific return information follows the description of each function in this chapter. Information about specific error codes returned by each function is presented in the following section.
See Also:
For more information about return codes and error handling, see the section "Error Handling". |
For a table showing the number of server round-trips required for individual OCI cache and object functions, refer to Appendix C, "OCI Function Server Round-trips".
Table 17-1 lists the external Oracle error codes which can be returned by each of the OCI navigational functions. The list following the table identifies what each error represents.
The ORA errors in Table 17-1 have the following meanings.
This section describes the OCI flush or refresh functions.
Function/Page | Purpose |
---|---|
Flush modified persistent objects in cache to server |
|
Refresh pinned persistent objects |
|
Flush a modified persistent object to the server |
|
Refresh a persistent object |
|
Copyright © 1996, 2002 Oracle Corporation. All Rights Reserved. |
|