Oracle Call Interface Programmer's Guide
Release 8.1.5

A67846-01

Library

Product

Contents

Prev

Index

A  B  C  D  E  F  G  H  I  J  K  L  M  N  O  P  Q  R  S  T  U  V  W  X  Y  Z 


A

aborting OCI calls, 2-33
abstract data type
representing in C applications, 10-8
ADO. See attribute descriptor object
ADT. See abstract data type
advanced queueing
dequeue function, 15-5
description, 9-25
enqueue function, 15-7
examples, 15-8
OCI and, 9-25
OCI descriptors for, 9-25
OCI functions for, 9-25
OCI vs. PL/SQL, 9-26
advanced queuing functions, 15-4
advantages
OCI, 1-3
allocation duration
example, 13-14
of objects, 13-14
application failover
callback example, 9-20
callback registration, 9-20
OCI callbacks, 9-18
applications
linking, 2-36
AQ. See advanced queueing.
arguments
attributes, 6-16
arrays
binds, 12-3
defines, 12-6
skip parameter for, 5-20
arrays of structures, 5-17
indicator variables, 5-20
OCI calls used, 5-20
skip parameters, 5-18
atomic nullness, 10-29
attribute descriptor object, 11-23
attributes
of handles, 2-12
of objects, 10-17
of parameter descriptors, 6-5
of parameters, 6-5
authentication management, 8-10
authorize functions, 15-87

B

BFILE
datatype, 3-20
bind functions, 15-42
bind handle
attributes, A-20
description, 2-10
bind operation, 4-5, 5-2, 12-2
associations made, 5-3
example, 5-6
initializing variables, 5-3
LOBs, 5-10
named datatypes, 5-10, 12-2
named vs. positional, 5-4
OCI array interface, 5-4
OCI_DATA_AT_EXEC mode, 5-11
PL/SQL, 5-5
positional vs. named, 5-4
ref cursor variables, 5-12
REFs, 5-10, 12-3
static arrays, 5-10
steps used, 5-6
binding
arrays, 12-3
OCINumber, 12-8
PL/SQL placeholders, 2-39
summary, 5-12
BLOB
datatype, 3-20
blocking modes, 2-36
branches
detaching, 8-7
resuming, 8-7
buffering LOB operations, 7-11

C

C datatypes
manipulating with OCI, 11-5
cache functions
server roundtrips, C-4
callbacks
application failover, 9-18
dynamic registrations, 9-15
for LOB operations, 7-13
for reading LOBs, 7-14
for writing LOBs, 7-15
from external procedures, 9-17
LOB streaming interface, 7-13
parameter modes, 15-63
registration for application failover, 9-20
restrictions, 9-16
user-defined functions, 9-11
canceling OCI calls, 2-33
CASE OTT parameter, 14-27
CHAR
external datatype, 3-16
character set form, 5-26
character set Id, 5-26
Unicode, A-20, A-22
CHARZ
external datatype, 3-17
checkerr() function
code listing, 2-28
CLOB
datatype, 3-20
code
example programs, B-1
list of demonstration programs, B-1
CODE OTT parameter, 14-26
codes
functions, 15-230
coding guidelines
function names, 2-36
reserved words, 2-35
coherency
of object cache, 13-4
collections
attributes, 6-13
data manipulation functions, 11-18
describing, 6-2
description, 11-17
functions for manipulating, 11-18
scanning functions, 11-19
columns
attributes, 6-5, 6-15
commit, 2-26
in object applications, 13-14
one-phase for global transactions, 8-7
two-phase for global transactions, 8-7
complex object retrieval, 10-20
implementing, 10-23
navigational prefetching, 10-24
complex object retrieval (COR) descriptor, 2-16
attributes, A-26
complex object retrieval (COR) handle, 2-11
attributes, A-25
CONFIG OTT parameter, 14-27
connect functions, 15-87
connection mode
non-blocking, 2-36
consistency
of object cache, 13-4
copying
objects, 10-32
COR, see complex object retrieval
creating
objects, 10-32

D

data cartridges
OCI functions, xxxiv, 2-3
data definition language
SQL statements, 1-7
data manipulation language
SQL statements, 1-8
data structures
new for 8.0, 2-5
database connection
for object applications, 10-10
databases
attributes, 6-19
describing, 6-2
datatype code
internal, 3-5
datatype mapping
Oracle methodology, 11-4
OTT, 14-10
datatype mapping and manipulation functions
server roundtrips, C-6
datatypes
BFILE, 3-20
BLOB, 3-20
CLOB, 3-20
conversions, 3-21
direct path loading, 9-39, A-47
external, 3-4, 3-7
FILE, 3-20
for piecewise operations, 5-33
internal, 3-3, 3-5
manipulating with OCI, 11-5
mapping from Oracle to C, 11-2
NCLOB, 3-21
Oracle, 3-2
DATE
external datatype, 3-14
DDL. See data definition language
default file name extensions
OTT, 14-36
default name mapping
OTT, 14-36
define
arrays, 12-6
return and error codes, 2-28
define functions, 15-42
define handle
attributes, A-22
description, 2-10
define operation, 4-14, 5-13, 12-4
example, 5-14
LOBs, 5-17
named datatypes, 5-16, 12-4
piecewise fetch, 5-17
PL/SQL output variables, 5-17
REFs, 5-16, 12-4
static arrays, 5-17
steps used, 5-14
defining
OCINumber, 12-8
deletes
positioned, 2-34
demonstration programs, B-1
list, B-1
describe
explicit, 4-13
explicit and implicit, 6-5
implicit, 4-11
of collections, 6-2
of databases, 6-2
of packages, 6-2
of schemas, 6-2
of sequences, 6-2
of stored functions, 6-2
of stored procedures, 6-2
of synonyms, 6-2
of tables, 6-2
of types, 6-2
of views, 6-2
select-list, 4-10
describe functions, 15-42
describe handle
attributes, A-24
description, 2-11
describe operation
server roundtrips, C-5
descriptor, 2-14
allocating, 2-22
complex object retrieval, 2-16
objects, 11-23
parameter, 2-16
ROWID, 2-16
snapshot, 2-15
descriptor functions, 15-27
descriptor objects, 11-23
detaching branches, 8-7
direct path handles, 2-12
direct path loading, 9-37
column array handle attributes, A-42
column parameter attributes, A-44
context handle attributes, A-39
datatypes of columns, 9-39, A-47
direct path column array handle, 9-40
direct path context handle, 9-39
direct path stream handle, 9-40
example, 9-42
functions, 9-41
handle attributes, A-39
handles, 9-39
limitations, 9-38
stream handle attributes, A-43
direct path loading functions, 15-72
DML. See data manipulation language
DML with RETURNING clause
See RETURNING clause
duration
example, 13-14
of objects, 13-14

E

embedded objects
fetching, 10-15
embedded SQL, 1-11
mixing with OCI calls, 1-11
environment handle
attributes, A-3
description, 2-8
error codes
define calls, 2-28
navigational functions, 16-6
error handle
attributes, A-6
description, 2-9
errors
example of handling, 2-28
handling, 2-27
handling in object applications, 10-35
ERRTYPE OTT parameter, 14-27
example
demonstration programs, B-1
non-blocking mode, 2-37
using OCIThread, 9-9
executing SQL statements, 4-6
execution
against multiple servers, 4-5
modes, 4-7
execution snapshots, 4-7
extensions
OTT default file name, 14-36
external datatypes, 3-4, 3-7
CHAR, 3-16
CHARZ, 3-17
conversions, 3-21
DATE, 3-14
FLOAT, 3-11
INTEGER, 3-11
LOBs, 3-18
LONG, 3-13
LONG RAW, 3-15
LONG VARCHAR, 3-16
LONG VARRAW, 3-16
named data types, 3-18
NUMBER, 3-10
RAW, 3-14
REF, 3-18
ROWID, 3-13
SQLT_BLOB, 3-18
SQLT_CLOB, 3-18
SQLT_NCLOB, 3-18
SQLT_NTY, 3-18
SQLT_REF, 3-18
STRING, 3-11
UNSIGNED, 3-15
VARCHAR, 3-13
VARCHAR2, 3-8
VARNUM, 3-12
VARRAW, 3-15
external procedure functions
return codes, 18-3
with_context type, 18-3
external procedures
OCI callbacks, 9-17

F

fetch
piecewise, 5-32, 5-36
fetch operation, 4-14
LOB data, 4-15
setting prefetch count, 4-15
FILE
associating with OS file, 7-5
datatype, 3-20
locator, 7-4
FLOAT
external datatype, 3-11
flushing, 13-10
object changes, 10-14
objects, 13-10
freeing
objects, 10-32, 13-9
function names
coding guidelines, 2-36
functions
attributes, 6-8
codes, 15-230
new and updated calls, 1-12

G

global transactions, 8-4
GTRID. See transaction identifier

H

handle attributes, 2-12
reading, 2-12
setting, 2-12
handle functions, 15-27
handles, 2-6
advantages of, 2-8
allocating, 2-7, 2-22
bind handle, 2-10
C datatypes, 2-6
child freed when parent freed, 2-7
define handle, 2-10
describe handle, 2-11
direct path, 2-12
environment handle, 2-8
error handle, 2-9
freeing, 2-7
hierarchy of, 2-8
process, 2-12
process attributes, A-49
server handle, 2-9
service context handle, 2-9
statement handle, 2-10
subscription, 2-11, 9-31
transaction handle, 2-9
types, 2-6
user session handle, 2-9
HFILE OTT parameter, 14-26

I

indicator variable, 2-31
arrays of structures, 5-20
for named datatypes, 2-31, 2-33
for REF, 2-31
for REFs, 2-33
named datatype defines, 12-5
PL/SQL OUT binds, 12-5
REF defines, 12-5
with named datatype bind, 12-3
with REF bind, 12-3
INITFILE OTT parameter, 14-26
INITFUNC OTT parameter, 14-26
initialize functions, 15-87
inserts
piecewise, 5-32, 5-34
INTEGER
external datatype, 3-11
internal datatypes, 3-3, 3-5
conversions, 3-21
datatype codes, 3-5
intype file
providing when running OTT, 14-8
structure of, 14-29
INTYPE OTT parameter, 14-25

K

key words, xxxv, 2-35

L

linking, 2-36
issues, 1-25
modes, 1-25
support for single-task, 1-27
lists
attributes, 6-18
LOB, 7-2
amount and offset parameters, 15-108
attributes of transient objects, 7-6
binding, 5-10
buffering, 7-11
callbacks, 7-13
character sets, 15-108
creating, 7-4
creating temporary, 7-18
defining, 5-17
duration of temporary, 7-18
example of temporary, 7-19
external datatypes, 3-18
fetching data, 4-15
fixed-width character sets, 15-108
freeing temporary, 7-18
locator, 2-15
modifying, 7-4
OCI functions, 7-6
temporary, 7-17
varying-width character sets, 15-108
LOB functions, 15-107
server roundtrips, C-2
LOB locator, 2-15, 7-2
attributes, A-25
locator, 2-14
for FILEs, 7-4
for LOB datatype, 2-15, 7-2
locking, 13-12
objects, 13-12
optimistic model, 13-13
LONG
external datatype, 3-13
LONG RAW
external datatype, 3-15
LONG VARCHAR
external datatype, 3-16
LONG VARRAW
external datatype, 3-16

M

marking
objects, 13-9
MDO. See method descriptor object
meta-attributes
of objects, 10-17
of persistent objects, 10-17
of transient objects, 10-20
method descriptor object, 11-23
migration
7.x to 8.0, 1-22
session, 8-11, 15-103
miscellaneous functions, 15-215
multiple servers
executing statement against, 4-5
multi-threaded development
basic concepts, 8-15

N

named datatypes
binding, 5-10, 12-2
binding and defining, 12-6
defining, 5-16, 12-4
definition, 3-18
external datatypes, 3-18
indicator variable for, 2-31
indicator variables, 2-33
navigation, 13-17
navigational functions
error codes, 16-6
return values, 16-5
terminology, 16-4
NCHAR
issues, 5-26
NCLOB
datatype, 3-21
nested table
element ordering, 11-21
functions for manipulating, 11-20
new features, 1-12
benefits, 1-12
introduction, 1-12
NLS
OCI functions, xxxiv, 2-3
non-blocking mode, 2-36
example, 2-37
no-op
definition, 16-22
null indicator struct, 10-29
generated by OTT, 10-9
nullness
atomic, 10-29
of objects, 10-29
NULLs
detecting, 2-32
inserting, 2-32
inserting into database, 2-31
inserting using indicator variables, 2-31
NUMBER
external datatype, 3-10

O

object applications
commit, 13-14
database connection, 10-10
rollback, 13-14
object cache, 13-2
coherency, 13-4
consistency, 13-4
initializing, 10-10
loading objects, 13-7
memory parameters, 13-5
operations on, 13-6
removing objects, 13-7
setting the size of, 13-5
object functions
See navigational functions.
server roundtrips, C-4
object identifier
for persistent objects, 10-5
object reference, 10-33
object reference. See REF
object runtime environment
initializing, 10-10
object type translator
sample output, 10-9
See OTT
use with OCI, 10-8
objects
accessing with OCI, 14-19
allocation duration, 13-14
array pin, 10-13
attributes, 10-17
manipulating, 10-13
client-side cache, 13-2
copying, 10-32
creating, 10-32
duration, 13-14
flushing, 13-10
flushing changes, 10-14
freeing, 10-32, 13-9
lifetime, 16-2
LOB attribute of, 7-5
LOB attributes of transient objects, 7-6
locking, 13-12
manipulating with OCI, 14-19
marking, 10-14, 13-9
memory layout of instance, 13-16
memory management, 13-2
meta-attributes, 10-17
navigation, 13-17
simple, 13-17
nullness, 10-29
OCI object application structure, 10-4
persistent, 10-5, 10-6
pin count, 10-28
pin duration, 13-14
pinning, 10-12, 13-7
refreshing, 13-11
secondary memory, 13-16
terminology, 16-2
top-level memory, 13-16
transient, 10-5, 10-7
types, 10-5, 16-2
unmarking, 13-10
unpinning, 10-28, 13-8
use with OCI, 10-3
OCI
accessing and manipulating objects, 14-19
advantages, 1-3
new features, 1-12
object support, 1-6
overview, 1-2
parts of, 1-5
OCI application
compiling, 1-4
general structure, 2-3
initialization example, 2-24
linking, 1-4
steps, 2-17
structure, 2-3
structure using objects, 10-4
terminating, 2-26
using the OTT with, 14-18
with objects
initializing, 10-10
OCI environment
initializing for objects, 10-10
OCI functions
canceling calls, 2-33
codes, 15-230
data cartridges, xxxiv, 2-3
new and updated calls, 1-12
NLS, xxxiv, 2-3
not supported, 1-21
obsolescent, 1-19
return codes, 2-27, 2-29
OCI navigational functions, 13-19
flush functions, 13-20
mark functions, 13-20
meta-attribute accessor functions, 13-20
miscellaneous functions, 13-21
naming scheme, 13-19
pin/unpin/free functions, 13-19
OCI process
initializing for objects, 10-10
OCI program. See OCI application
OCI relational functions
advanced queuing and publish-subscribe, 15-4
connect, authorize, and initialize, 15-87
guide to reference entries, 18-2
OCI_ATTR_ALLOC_DURATION
environment handle attribute, A-4
OCI_ATTR_AUTOCOMMIT_DDL
attribute, 6-20
OCI_ATTR_BUF_ADDR, A-43
OCI_ATTR_BUF_SIZE, A-39, A-43
OCI_ATTR_CACHE
attribute, 6-15
OCI_ATTR_CACHE_ARRAYFLUSH
environment handle attribute, A-3
OCI_ATTR_CACHE_MAX_SIZE
environment handle attribute, A-3
OCI_ATTR_CACHE_OPT_SIZE
environment handle attribute, A-3
OCI_ATTR_CATALOG_LOCATION
attribute, 6-20
OCI_ATTR_CHAR_COUNT
bind handle attribute, A-20
define handle attribute, A-22
use of, 5-28
OCI_ATTR_CHARSET_FORM
attribute, 6-11, 6-14, 6-16
bind handle attribute, A-20
define handle attribute, A-23
OCI_ATTR_CHARSET_ID, A-39, A-46
attribute, 6-11, 6-14, 6-16, 6-18, 6-19
bind handle attribute, A-20
define handle attribute, A-22
OCI_ATTR_CLUSTERED
attribute, 6-7
OCI_ATTR_COL_COUNT, A-42
OCI_ATTR_COLLECTION_ELEMENT
attribute, 6-9
OCI_ATTR_COLLECTION_TYPECODE
attribute, 6-9
OCI_ATTR_COMPLEXOBJECT_ COLL_OUTOFLINE
COR handle attribute, A-25
OCI_ATTR_COMPLEXOBJECT_LEVEL
COR handle attribute, A-25
OCI_ATTR_COMPLEXOBJECTCOMP _TYPE_LEVEL
COR descriptor attribute, A-26
OCI_ATTR_COMPLEXOBJECTCOMP_TYPE
COR descriptor attribute, A-26
OCI_ATTR_CURSOR_COMMIT_ BEHAVIOR
attribute, 6-20
OCI_ATTR_DATA_SIZE, A-47
attribute, 6-10, 6-13, 6-15, 6-16
OCI_ATTR_DATA_TYPE, A-47
attribute, 6-10, 6-13, 6-15, 6-16
OCI_ATTR_DATE_FORMAT, A-39
OCI_ATTR_DATEFORMAT, A-47
OCI_ATTR_DBA
attribute, 6-7
OCI_ATTR_DIRPATH_MODE, A-40
OCI_ATTR_DIRPATH_NOLOG, A-40
OCI_ATTR_DIRPATH_PARALLEL, A-40
OCI_ATTR_DML_ROW_OFFSET, A-6
OCI_ATTR_DURATION
attribute, 6-7
OCI_ATTR_ENCAPSULATION
attribute, 6-11
OCI_ATTR_ENV
server handle attribute, A-9
service context handle attribute, A-7
OCI_ATTR_EXTERNAL_NAME
server handle attribute, A-9
OCI_ATTR_FOCBK
server handle attribute, A-10
OCI_ATTR_HAS_DEFAULT
attribute, 6-17
OCI_ATTR_HAS_FILE
attribute, 6-9
OCI_ATTR_HAS_LOB
attribute, 6-9
OCI_ATTR_HAS_NESTED_TABLE
attribute, 6-9
OCI_ATTR_HW_MARK
attribute, 6-15
OCI_ATTR_IN_V8_MODE
server handle attribute, A-10
service context handle attribute, A-8
OCI_ATTR_INCR
attribute, 6-14
OCI_ATTR_INDEX_ONLY
attribute, 6-7
OCI_ATTR_INTERNAL_NAME
server handle attribute, A-10
OCI_ATTR_IOMODE
attribute, 6-17
OCI_ATTR_IS_CONSTRUCTOR
attribute, 6-11
OCI_ATTR_IS_DESTRUCTOR
attribute, 6-11
OCI_ATTR_IS_INCOMPLETE_TYPE
attribute, 6-9
OCI_ATTR_IS_INVOKER_RIGHTS
attribute, 6-8, 6-10
OCI_ATTR_IS_MAP
attribute, 6-12
OCI_ATTR_IS_NULL
attribute, 6-15, 6-17
OCI_ATTR_IS_OPERATOR
attribute, 6-11
OCI_ATTR_IS_ORDER
attribute, 6-12
OCI_ATTR_IS_PREDEFINED_TYPE
attribute, 6-9
OCI_ATTR_IS_RNDS
attribute, 6-12
OCI_ATTR_IS_RNPS
attribute, 6-12
OCI_ATTR_IS_SELFISH
attribute, 6-12
OCI_ATTR_IS_SYSTEM_GENERATED_TYPE
attribute, 6-9
OCI_ATTR_IS_SYSTEM_TYPE
attribute, 6-9
OCI_ATTR_IS_TEMPORARY
attribute, 6-7
OCI_ATTR_IS_TRANSIENT_TYPE
attribute, 6-9
OCI_ATTR_IS_WNDS
attribute, 6-12
OCI_ATTR_IS_WNPS
attribute, 6-12
OCI_ATTR_LEVEL
attribute, 6-17
OCI_ATTR_LINK
attribute, 6-14, 6-18
OCI_ATTR_LIST_ARGUMENTS
attribute, 6-8, 6-11
OCI_ATTR_LIST_COLUMNS, A-40
attribute, 6-7
OCI_ATTR_LIST_OBJECTS
attribute, 6-19
OCI_ATTR_LIST_SCHEMAS
attribute, 6-19
OCI_ATTR_LIST_SUBPROGRAMS
attribute, 6-8
OCI_ATTR_LIST_TYPE
attribute, 6-18
OCI_ATTR_LIST_TYPE_ATTRS
attribute, 6-10
OCI_ATTR_LIST_TYPE_METHODS
attribute, 6-10
OCI_ATTR_LOBEMPTY
LOB locator attribute, A-25
OCI_ATTR_LOCKING_MODE
attribute, 6-20
OCI_ATTR_MAP_METHOD
attribute, 6-10
OCI_ATTR_MAX
attribute, 6-14
OCI_ATTR_MAX_CATALOG_ NAMELEN
attribute, 6-20
OCI_ATTR_MAX_COLUMN_ NAMELEN
attribute, 6-19
OCI_ATTR_MAX_PROC_NAMELEN
attribute, 6-19
OCI_ATTR_MAXDATA_SIZE
bind handle attribute, A-21
use with binding, 5-27
OCI_ATTR_MEMPOOL_APPNAME, A-49
OCI_ATTR_MEMPOOL_HOMENAME, A-49
OCI_ATTR_MEMPOOL_INSTNAME, A-50
OCI_ATTR_MEMPOOL_SIZE, A-50
OCI_ATTR_MIGSESSION
user session handle attribute, A-12
OCI_ATTR_MIN
attribute, 6-14
OCI_ATTR_NAME, A-41, A-47
attribute, 6-8, 6-10, 6-11, 6-13, 6-14, 6-15, 6-16
OCI_ATTR_NCHARSET_ID
attribute, 6-19
OCI_ATTR_NONBLOCKING_MODE
server handle attribute, A-9
OCI_ATTR_NOWAIT_SUPORT
attribute, 6-20
OCI_ATTR_NUM_ATTRS
attribute, 6-5
OCI_ATTR_NUM_COLS, A-41, A-42
attribute, 6-7
OCI_ATTR_NUM_DML_ERRORS, A-14
OCI_ATTR_NUM_ELEMENTS
attribute, 6-13
OCI_ATTR_NUM_HANDLES
attribute, 6-19
OCI_ATTR_NUM_PARAMS
attribute, 6-5
OCI_ATTR_NUM_ROWS, A-42
OCI_ATTR_NUM_TYPE_ATTRS
attribute, 6-9
OCI_ATTR_NUM_TYPE_METHODS
attribute, 6-10
OCI_ATTR_OBJECT
environment handle attribute, A-4
OCI_ATTR_OBJECT_DETECTCHANGE
environment handle attribute, 13-13
OCI_ATTR_OBJID
attribute, 6-7, 6-14
OCI_ATTR_ORDER
attribute, 6-15
OCI_ATTR_ORDER_METHOD
attribute, 6-10
OCI_ATTR_OVERLOAD
attribute, 6-8
OCI_ATTR_PARAM
describe handle attribute, A-24
OCI_ATTR_PARAM_COUNT
describe handle attribute, A-24
statement handle attribute, A-17
OCI_ATTR_PARTITIONED
attribute, 6-7
OCI_ATTR_PASSWORD
user session handle attribute, A-12
OCI_ATTR_PDSCL
bind handle attribute, A-21, A-23
OCI_ATTR_PIN_DURATION
environment handle attribute, A-4
OCI_ATTR_PINOPTION
environment handle attribute, A-4
OCI_ATTR_POSITION
attribute, 6-16
OCI_ATTR_PRECISION, A-48
attribute, 6-5, 6-10, 6-13, 6-15, 6-17
OCI_ATTR_PREFETCH_MEMORY
statement handle attribute, A-18
OCI_ATTR_PREFETCH_ROWS
statement handle attribute, A-18
OCI_ATTR_PROC_MODE, A-50
OCI_ATTR_PTYPE
attribute, 6-6
OCI_ATTR_RADIX
attribute, 6-17
OCI_ATTR_REF_TDO
attribute, 6-7, 6-9, 6-11, 6-14, 6-16, 6-18
OCI_ATTR_ROW_COUNT, A-43
OCI_ATTR_ROWID
statement handle attribute, A-17
OCI_ATTR_ROWS_RETURNED
bind handle attribute, A-22
use with callbacks, 5-25
OCI_ATTR_SAVEPOINT_SUPPORT
attribute, 6-20
OCI_ATTR_SCALE, A-48
attribute, 6-10, 6-13, 6-15, 6-17
OCI_ATTR_SCHEMA_NAME, A-41
attribute, 6-11, 6-13, 6-14, 6-16, 6-17
OCI_ATTR_SEQ
attributes, 6-14
OCI_ATTR_SERVER
service context handle attribute, A-7
OCI_ATTR_SERVER_GROUP
server handle attribute, A-11
OCI_ATTR_SESSION
service context handle attribute, A-7
OCI_ATTR_SHARED_HEAP_ALLOC, A-6
OCI_ATTR_STMT_TYPE
statement handle attribute, A-17
OCI_ATTR_STREAM_OFFSET, A-44
OCI_ATTR_SUB_NAME, A-42
attribute, 6-18
OCI_ATTR_SUBSCR_CALLBACK, A-37
OCI_ATTR_SUBSCR_CTX, A-37
OCI_ATTR_SUBSCR_NAME, A-38
OCI_ATTR_SUBSCR_NAMESPACE, A-37
OCI_ATTR_SUBSCR_PAYLOAD, A-38
OCI_ATTR_TABLESPACE
attribute, 6-7
OCI_ATTR_TIMESTAMP
attribute, 6-6
OCI_ATTR_TRANS
service context handle attribute, A-7
OCI_ATTR_TRANS_NAME
transaction handle attribute, A-13
OCI_ATTR_TYPE_NAME
attribute, 6-11, 6-13, 6-16, 6-17
OCI_ATTR_TYPECODE
attribute, 6-9, 6-10, 6-13, 6-16
OCI_ATTR_USRNAME
user session handle attribute, A-12
OCI_ATTR_VERSION
attribute, 6-9, 6-19
OCI_ATTR_XID
transaction handle attribute, A-13
OCI_EVENTS
mode for receiving notifications, 9-30
OCI_LOCK_X_NOWAIT
parameter usage, 13-13
OCI_NUM_SHARED_PROCS, 2-22
OCI_PTYPE_ARG
attributes, 6-16
OCI_PTYPE_COL
attributes, 6-15
OCI_PTYPE_COLL
attributes, 6-13
OCI_PTYPE_DATABASE
attributes, 6-19
OCI_PTYPE_FUNC
attributes, 6-8
OCI_PTYPE_LIST
attributes, 6-18
OCI_PTYPE_PKG
attributes, 6-8
OCI_PTYPE_PROC
attributes, 6-8
OCI_PTYPE_SCHEMA
attributes, 6-19
OCI_PTYPE_SYN
attributes, 6-14
OCI_PTYPE_TABLE
attributes, 6-7
OCI_PTYPE_TYPE
attributes, 6-9
OCI_PTYPE_TYPE_ATTR
attributes, 6-10
OCI_PTYPE_TYPE_FUNC
attributes, 6-11
OCI_PTYPE_TYPE_PROC
attributes, 6-11
OCI_PTYPE_VIEW
attributes, 6-7
OCI_SHARED_MODE, 2-21
OCI_TYPECODE
values, 3-23, 3-24, 3-25
OCIAQAgent
descriptor attributes, A-35
OCIAQDeq(), 15-5
OCIAQDeqOptions
descriptor attributes, A-28
OCIAQEnq(), 15-7
OCIAQEnqOptions
descriptor attributes, A-26
OCIAQListen(), 15-19
OCIAQMsgProperties
descriptor attributes, A-31
OCIArray, 11-17
binding and defining, 11-17, 12-6
OCIArray manipulation
code example, 11-19
OCIAttrGet(), 15-28
used for describing, 4-11
OCIAttrSet(), 15-29
OCIBindArrayOfStruct(), 15-43
OCIBindByName(), 15-44
OCIBindByPos(), 15-48
OCIBindDynamic(), 15-52
OCIBindObject(), 15-56
OCIBreak(), 15-216
use of, 2-33, 2-37
OCICacheFlush(), 16-9
OCICacheFree(), 16-48
OCICacheRefresh(), 16-11
OCICacheUnmark(), 16-17
OCICacheUnpin(), 16-49
OCIColl, 11-17
binding and defining, 11-17
OCICollAppend(), 17-6
OCICollAssign(), 17-7
OCICollAssignElem(), 17-8
OCICollGetElem(), 17-10
OCICollIsLocator(), 17-13
OCICollMax(), 17-14
OCICollSetUpdateStatus(), 17-15
OCICollSize(), 17-16
OCICollTrim(), 17-18
OCIComplexObject
use of, 10-23
OCIComplexObjectComp
use of, 10-23
OCIDate, 11-7
binding and defining, 11-7, 12-6
OCIDate manipulation
code example, 11-8
OCIDateAddDays(), 17-28
OCIDateAddMonths(), 17-29
OCIDateAssign(), 17-30
OCIDateCheck(), 17-31
OCIDateCompare(), 17-33
OCIDateDaysBetween(), 17-34
OCIDateFromText(), 17-35
OCIDateGetDat(), 17-37
OCIDateGetTime(), 17-38
OCIDateLastDay(), 17-39
OCIDateNextDay(), 17-40
OCIDateSetDate(), 17-41
OCIDateSetTime(), 17-42
OCIDateSysDate(), 17-43
OCIDateToText(), 17-44
OCIDateZoneToZone(), 17-46
OCIDefineArrayOfStruct(), 15-58
OCIDefineByPos(), 15-59
OCIDefineDynamic(), 15-63
OCIDefineObject(), 15-65
OCIDescAlloc(), 15-31
OCIDescFree(), 15-33
OCIDescribeAny(), 15-67
usage examples, 6-20
using, 6-2
OCIDirPathAbort(), 15-73
OCIDirPathColArrayEntryGet(), 15-74
OCIDirPathColArrayEntrySet(), 15-76
OCIDirPathColArrayReset(), 15-79
OCIDirPathColArrayRowGet(), 15-78
OCIDirPathColArrayToStream(), 15-80
OCIDirPathFinish(), 15-82
OCIDirPathFlushRow(), 15-83
OCIDirPathPrepare(), 15-85
OCIDirPathStreamLoad(), 15-83
OCIDirPathStreamReset(), 15-86
OCIDuration
use of, 13-7, 13-14
OCIDurationBegin(), 15-109
OCIDurationEnd(), 15-110
OCIEnvCallback, 9-15
OCIEnvCreate(), 15-88
OCIEnvInit(), 15-91
OCIErrorGet(), 15-217
OCIExtProcAllocCallmemory(), 18-5
OCIExtProcGetEnv(), 18-8
OCIExtProcRaiseExcp(), 18-6
OCIExtProcRaiseExcpWithMsg(), 18-7
OCIHandleAlloc(), 15-34
OCIHandleFree(), 15-37
OCIInd
use of, 10-29
OCIInitialize(), 15-93
shared mode, 2-20
OCIIter, 11-17
binding and defining, 11-17
usage example, 11-19
OCIIterCreate(), 17-19
OCIIterDelete(), 17-20
OCIIterGetCurrent(), 17-21
OCIIterInit(), 17-22
OCIIterNext(), 17-23
OCIIterPrev(), 17-25
OCILdaToSvcCtx(), 15-219
OCILobAppend(), 15-111
OCILobAssign(), 15-112
OCILobCharSet(), 15-114, 15-115
OCILobClose(), 15-116
OCILobCopy(), 15-117
OCILobCreateTemporary(), 15-119
OCILobDisableBuffering(), 15-121
OCILobEnableBuffering(), 15-122
OCILobErase(), 15-123
OCILobFileClose(), 15-124
OCILobFileCloseAll(), 15-125
OCILobFileExists(), 15-126
OCILobFileIsOpen(), 15-129
OCILobFileOpen(), 15-130
OCILobFlushBuffer(), 15-132
OCILobFreeTemporary(), 15-134
OCILobGetChunkSize(), 15-135
OCILobGetFileName(), 15-127
OCILobGetLength(), 15-137
OCILobIsEqual(), 15-138
OCILobIsOpen(), 15-139
OCILobIsTemporary(), 15-141
OCILobLoadFromFile(), 15-142
OCILobLocatorAssign(), 15-144
OCILobLocatorIsInit(), 15-146
OCILobOpen(), 15-147
OCILobRead(), 15-148
OCILobSetFileName(), 15-131
OCILobTrim(), 15-152
OCILobWrite(), 15-153
OCILobWriteAppend(), 15-157
OCILockOpt
possible values, 16-28, 16-54
OCILogoff(), 15-96
OCILogon(), 15-97
using, 2-23
OCINumber, 11-10
bind example, 12-8
binding and defining, 11-10, 12-6
define example, 12-8
OCINumber manipulation
code example, 10-13, 11-13
OCINumberAbs(), 17-50
OCINumberAdd(), 17-51
OCINumberArcCos(), 17-52
OCINumberArcSin(), 17-53
OCINumberArcTan(), 17-54
OCINumberArcTan2(), 17-55
OCINumberAssign(), 17-56
OCINumberCeil(), 17-57
OCINumberCompare(), 17-58
OCINumberCos(), 17-59
OCINumberDec(), 17-60
OCINumberDiv(), 17-61
OCINumberExp(), 17-62
OCINumberFloor(), 17-63
OCINumberFromInt(), 17-64
OCINumberFromReal(), 17-65
OCINumberFromText(), 17-66
OCINumberHypCos(), 17-68
OCINumberHypSin(), 17-69
OCINumberHypTan(), 17-70
OCINumberInc(), 17-71
OCINumberIntPower(), 17-72
OCINumberIsInt(), 17-73
OCINumberIsZero(), 17-74
OCINumberLn(), 17-75
OCINumberLog(), 17-76
OCINumberMod(), 17-77
OCINumberMul(), 17-78
OCINumberNeg(), 17-79
OCINumberPower(), 17-80
OCINumberPrec(), 17-81
OCINumberRound(), 17-82
OCINumberSetPi(), 17-83
OCINumberSetZero(), 17-84
OCINumberShift(), 17-85
OCINumberSign(), 17-86
OCINumberSin(), 17-87
OCINumberSqrt(), 17-88
OCINumberSub(), 17-89
OCINumberTan(), 17-90
OCINumberToInt(), 17-91
OCINumberToReal(), 17-92
OCINumberToText(), 17-93
OCINumberTrunc(), 17-95
OCIObjectArrayPin(), 16-50
OCIObjectCopy(), 16-33
OCIObjectExists(), 16-25
OCIObjectFlush(), 16-13
OCIObjectFree(), 16-52
OCIObjectGetAttr(), 16-35
OCIObjectGetInd(), 16-37
OCIObjectGetObjectRef(), 16-38
OCIObjectGetTypeRef(), 16-39
OCIObjectIsDirty(), 16-30
OCIObjectIsLocked(), 16-31
OCIObjectLifetime
possible values, 16-27
OCIObjectLock(), 16-40
OCIObjectLockNoWait(), 16-41
OCIObjectMarkDelete(), 16-18
OCIObjectMarkDeleteByRef(), 16-19
OCIObjectMarkStatus
possible values, 16-28
OCIObjectMarkUpdate(), 16-20
OCIObjectNew(), 16-42
OCIObjectPin(), 16-54
OCIObjectPinCountReset(), 16-57
OCIObjectPinTable(), 16-58
OCIObjectRefresh(), 16-14
OCIObjectSetAttr(), 16-45
OCIObjectUnmark(), 16-22
OCIObjectUnmarkByRef(), 16-23
OCIObjectUnpin(), 16-60
OCIParamGet(), 15-39
used for describing, 4-11
OCIParamSet(), 15-41
OCIPasswordChange(), 15-220
OCIPinOpt
use of, 13-7
OCIRaw, 11-16
binding and defining, 11-16, 12-6
OCIRaw manipulation
code example, 11-17
OCIRawAllocSize(), 17-97
OCIRawAssignBytes(), 17-98
OCIRawAssignRaw(), 17-99
OCIRawPtr(), 17-100
OCIRawResize(), 17-101
OCIRawSize(), 17-102
OCIRef, 11-22
binding and defining, 11-22
usage example, 11-22
OCIRefAssign(), 17-104
OCIRefClear(), 17-105
OCIRefFromHex(), 17-106
OCIRefHexSize(), 17-107
OCIRefIsEqual(), 17-108
OCIRefIsNull(), 17-109
OCIRefToHex(), 17-110
OCIReset(), 15-222
use of, 2-37
OCIRowid, 2-16
OCIServerAttach(), 15-99
shadow processes, 15-100
OCIServerDetach(), 15-101
OCIServerVersion(), 15-223
OCISessionBegin(), 15-102
OCISessionEnd(), 15-105
OCIStmtExecute(), 15-161
prefetch during, 4-6
use of iters parameter, 4-6
OCIStmtFetch(), 15-164
OCIStmtGetBind(), 15-70
OCIStmtGetPieceInfo(), 15-165
OCIStmtPrepare(), 15-167
preparing SQL statements, 4-4
shared mode, 2-21
OCIStmtSetPieceInfo(), 15-169
OCIString, 11-15
binding and defining, 11-15, 12-6
OCIString manipulation
code example, 11-15
OCIStringAllocSize(), 17-112
OCIStringAssign(), 17-113
OCIStringAssignText(), 17-114
OCIStringPtr(), 17-115
OCIStringResize(), 17-116
OCIStringSize(), 17-117
OCISubscriptionDisable(), 15-20
OCISubscriptionEnable(), 15-21
OCISubscriptionPost(), 15-22
OCISubscriptionRegister(), 15-24
OCISubscriptionUnRegister(), 15-26
OCISvcCtxToLda(), 15-224
OCITable, 11-17
binding and defining, 11-17, 12-6
OCITableDelete(), 17-119
OCITableExists(), 17-120
OCITableFirst(), 17-121
OCITableLast(), 17-122
OCITableNext(), 17-123
OCITablePrev(), 17-124
OCITableSize(), 17-125
OCITerminate(), 15-106
OCIThreadClose(), 15-173
OCIThreadCreate(), 15-174
OCIThreadHandleGet(), 15-176
OCIThreadHndDestroy(), 15-177
OCIThreadHndInit(), 15-178
OCIThreadIdDestroy(), 15-179
OCIThreadIdGet(), 15-180
OCIThreadIdInit(), 15-181
OCIThreadIdNull(), 15-182
OCIThreadIdSame(), 15-183
OCIThreadIdSet(), 15-184
OCIThreadIdSetNull(), 15-185
OCIThreadInit(), 15-186
OCIThreadIsMulti(), 15-187
OCIThreadJoin(), 15-188
OCIThreadKeyDestroy(), 15-189
OCIThreadKeyGet(), 15-190
OCIThreadKeyInit(), 15-191
OCIThreadKeySet(), 15-192
OCIThreadMutexAcquire(), 15-193
OCIThreadMutexDestroy(), 15-194
OCIThreadMutexInit(), 15-195
OCIThreadMutexRelease(), 15-196
OCIThreadProcessInit(), 15-197
OCIThreadTerm(), 15-198
OCITransCommit(), 15-200
OCITransDetach(), 15-203
OCITransForget(), 15-204
OCITransPrepare(), 15-205
OCITransRollback(), 15-206
OCITransStart(), 15-207
OCIType
description, 11-23
OCITypeArrayByName(), 16-63
OCITypeArrayByRef(), 16-66
OCITypeByName(), 16-68
OCITypeByRef(), 16-70
OCITypeElem
description, 11-23
OCITypeMethod
description, 11-23
OCIUserCallbackGet(), 15-225
OCIUserCallbackRegister(), 15-227
OID. See object identifier
optimistic locking
implementing, 13-13
Oracle Call Interface. See OCI
Oracle datatypes, 3-2
mapping to C, 11-2
Oracle8 datatypes
binding and defining, 12-6
oratypes.h
contents, 3-27
ORE. See object runtime environment
OTT
command line, 14-6
command line syntax, 14-23
creating types in the database, 14-5
datatype mapping, 14-10
intype file, 14-29
outtype file, 14-16
overview, 14-2
parameters, 14-24
providing an intype file, 14-8
reference, 14-22
restriction, 14-37
using, 14-1
OTT initialization function
calling, 14-20
tasks of, 14-22
OTT parameters
CASE, 14-27
CODE, 14-26
CONFIG, 14-27
ERRTYPE, 14-27
HFILE, 14-26
INITFILE, 14-26
INITFUNC, 14-26
INTYPE, 14-25
OUTTYPE, 14-25
SCHEMA_NAMES, 14-28
USERID, 14-24
where they appear, 14-28
OTT. See object type translator
outtype file, 14-29
when running OTT, 14-16
OUTTYPE OTT parameter, 14-25

P

packages
attributes, 6-8
describing, 6-2
parameter descriptor, 2-16
attributes, 6-5, A-24
parameter descriptor object, 11-23
parameters
attributes, 6-5
modes, 15-2, 18-2
passing strings, 2-31
string length, 15-3
password management, 8-10, 8-12
PDO. See parameter descriptor object
persistent objects, 10-6
meta-attributes, 10-17
piecewise fetch, 5-36
piecewise operations, 5-34
fetch, 5-32, 5-37
in PL/SQL, 5-36
insert, 5-32
update, 5-32
valid datatypes, 5-33
pin count, 10-28
pin duration
example, 13-14
of objects, 13-14
pinning, 13-7
pinning objects, 13-7
PL/SQL, 1-9
binding and defining nested tables, 5-30
binding and defining ref cursors, 5-30
binding placeholders, 2-39
defining output variables, 5-17
piecewise operations, 5-36
uses in OCI applications, 2-39
using in OCI applications, 2-39
using in OCI programs, 5-7
positioned, 2-34
deletes, 2-34
prefetching
during OCIStmtExecute(), 4-6
setting prefetch memory size, 4-15
setting row count, 4-15
procedures
attributes, 6-8
process
handle attributes, A-49
process handle, 2-12
publish-subscribe
_SYSTEM_TRIG_ENABLED parameter, 9-33
COMPATIBLE parameter, 9-30
example, 9-33
functions, 9-30
handle attributes, 9-31, A-37
notification callback, 9-31
notification feature, 9-29
subscription handle, 9-31
publish-subscribe functions, 15-4

Q

query
explicit describe, 4-13
query. See SQL query

R

RAW
external datatype, 3-14
REF
binding, 5-10, 12-3
defining, 5-16, 12-4
external datatype, 3-18
indicator variable for, 2-31
retrieving from server, 10-11
ref cursor variables
binding, 5-12
ref cursors
binding and defining, 5-30
reference. See REF
refreshing, 13-11
objects, 13-11
REFs
indicator variables for, 2-33
registering
user callbacks, 9-11
relational functions
server roundtrips, C-2, C-6
release enhancements, 1-12
reserved namespaces, 2-35
reserved words, xxxv, 2-35
resuming branches, 8-7
return values
navigational functions, 16-5
RETURNING clause
binding with, 5-22
error handling, 5-23
initializing variables, 5-23
using with OCI
with REFs, 5-23
rollback, 2-26
in object applications, 13-14
roundtrips
See server roundtrips
ROWID
external datatype, 3-13
logical, 3-6
Universal ROWID, 3-6
used for positioned updates and deletes, 2-34
ROWID descriptor, 2-16

S

sample programs, B-1
sb1
definition, 3-27
sb2
definition, 3-27
sb4
definition, 3-27
SCHEMA_NAMES OTT parameter, 14-28
usage, 14-33
schemas
attributes, 6-19
describing, 6-2
secondary memory
of object, 13-16
select-list
describing, 4-10
sequences
attributes, 6-14
describing, 6-2
server handle
attributes, A-9
description, 2-9
setting in service context, 2-10
server roundtrips
cache functions, C-4
datatype mapping and manipulation functions, C-6
describe operation, C-5
LOB functions, C-2
object functions, C-4
relational functions, C-2, C-6
service context handle
attributes, A-7
description, 2-9
elements of, 2-9
session
migration, 8-11, 15-103
session management, 8-10, 8-13
shared data structures mode, 2-19
shared mode, 2-19
OCIInitialize(), 2-20
OCIStmtPrepare(), 2-21
using environmental variables, 2-21
single-task linking
support, 1-27
skip parameters
for arrays of structures, 5-18
for standard arrays, 5-20
snapshot descriptor, 2-15
snapshots
executing against, 4-7
SQL query
binding placeholders. See bind operation
defining output variables, 4-14, 5-13, 12-4
defining output variables. See define operation
fetching results, 4-14
statement type, 1-9
SQL statements, 1-7
binding placeholders in, 4-5, 5-2, 12-2
determining type prepared, 4-4
executing, 4-6
preparing for execution, 4-4
processing, 4-2
types
control statements, 1-8
data definition language, 1-7
data manipulation language, 1-8
embedded SQL, 1-11
PL/SQL, 1-9
queries, 1-9
SQLT typecodes, 3-25
SQLT_NTY
bind example, 12-13
define example, 12-14
description, 3-18
pre-allocating object memory, 12-5
SQLT_REF
definition, 3-18
description, 3-18
statement handle
attributes, A-14
description, 2-10
static arrays
binding, 5-10
defining, 5-17
stored functions
describing, 6-2
stored procedures
describing, 6-2
STRING
external datatype, 3-11
strings
passing as parameters, 2-31
structures
arrays of, 5-17
subscription handle, 2-11
attributes, A-37
sword
definition, 3-27
synonyms
attributes, 6-14
describing, 6-2

T

tables
attributes, 6-7
describing, 6-2
TDO
definition, 12-2
description, 11-23
obtaining, 11-23
type descriptor object. See TDO.
TDO. See type descriptor object
terminology
navigational functions, 16-4
used in this manual, 1-11
thread management functions, 15-171
thread safety, 8-14
advantages of, 8-14
and three-tier architectures, 8-14
basic concepts, 8-15
implementing with OCI, 8-15
mixing 7.x and 8.0 calls, 8-16
required OCI calls, 8-15
three-tier architectures
and thread safety, 8-14
top-level memory
of object, 13-16
transaction functions, 15-199
transaction handle
attributes, A-13
description, 2-9
transaction identifier, 8-4
transactional complexity
levels in OCI, 8-3
transactions
committing, 2-26
global, 8-4
branch states, 8-6
branches, 8-4
one-phase commit, 8-7
transactions identifier, 8-4
two-phase commit, 8-7
global examples, 8-8
initialization parameters, 8-10
local, 8-3
OCI functions for
transactions, 8-2
read-only, 8-3
rolling back, 2-26
serializable, 8-3
transient objects, 10-7
LOB
attributes, 7-6
meta-attributes, 10-20
type attributes
attributes, 6-10
type descriptor object, 11-23
type functions
attributes, 6-11
type procedures
attributes, 6-11
type reference, 10-33
typecodes, 3-23
types
attributes, 6-9
describing, 6-2

U

ub1
definition, 3-27
ub2
definition, 3-27
ub4
definition, 3-27
Unicode
and UTF-8, 5-29
character set Id, A-20, A-22
fixed width support, 5-28
OCILobRead(), 15-151
OCILobWrite(), 15-156
precautions, 5-29
Universal ROWID, 3-6
unmarking, 13-10
objects, 13-10
unpinning, 10-28, 13-8
objects, 13-8
UNSIGNED
external datatype, 3-15
updates, 2-34
piecewise, 5-32, 5-34
positioned, 2-34
upgrading
7.x to 8.0, 1-22
7.x to 8.0 OCI, 1-23
UROWID
Universal ROWID, 3-6
user memory
allocating, 2-17
user session handle
attributes, A-12
description, 2-9
setting in service context, 2-10
user-defined callback functions, 9-11
registering, 9-11
USERID OTT parameter, 14-24
utext
Unicode datatype, 5-29

V

values, 10-5
in object applications, 10-7
VARCHAR
external datatype, 3-13
VARCHAR2
external datatype, 3-8
VARNUM
external datatype, 3-12
VARRAW
external datatype, 3-15
views
attributes, 6-7
describing, 6-2

W

with_context
argument to external procedure functions, 18-3

X

XID. See transaction identifier
xtramem_sz parameter
using, 2-17


Prev
Oracle
Copyright © 1999 Oracle Corporation.

All Rights Reserved.

Library

Product

Contents