Melnick J.
Table of contents :
Send Us Your Comments……Page 33
Preface……Page 35
What’s New in Oracle Call Interface?……Page 45
Part I OCI Concepts……Page 53
1 Introduction and Upgrading……Page 55
Overview of OCI……Page 56
Building an OCI Application……Page 57
Parts of OCI……Page 58
Procedural and Non-Procedural Elements……Page 59
Object Support……Page 60
SQL Statements……Page 61
Simplified User Authentication and Password Management……Page 66
Extensions to Improve Application Performance and Scalability……Page 67
Associative and Navigational Interfaces……Page 68
Runtime Environment for Objects……Page 69
Object Type Translator……Page 70
Simplified Migration of Existing Applications……Page 71
Obsolescent OCI Routines……Page 72
OCI Routines Not Supported……Page 74
Compatibility……Page 75
Upgrading……Page 76
2 OCI Programming Basics……Page 79
OCI Program Structure……Page 80
Handles……Page 83
Allocating and Freeing Handles……Page 84
Service Context and Associated Handles……Page 87
Statement Handle, Bind Handle, and Define Handle……Page 88
Describe Handle……Page 89
Direct Path Handles……Page 90
Handle Attributes……Page 91
User Memory Allocation……Page 92
Descriptors……Page 93
Snapshot Descriptor……Page 94
LOB/FILE Datatype Locator……Page 95
Datetime and Interval Descriptors……Page 96
User Memory Allocation……Page 97
OCI Programming Steps……Page 98
Creating the OCI Environment……Page 99
Shared Data Mode……Page 100
Allocating Handles and Descriptors……Page 103
Application Initialization, Connection, and Session Creation……Page 104
Commit or Rollback……Page 107
Terminating the Application……Page 108
Error Handling……Page 109
Return and Error Codes for Truncation and Null Data……Page 111
Additional Coding Guidelines……Page 112
Inserting Nulls into a Column……Page 113
Indicator Variables……Page 114
Cancelling Calls……Page 116
Reserved Words……Page 117
Non-Blocking Mode……Page 119
Non-blocking Example……Page 120
Using PL/SQL in an OCI Program……Page 122
UTF-16 Environment Mode……Page 124
Character Length Semantics……Page 126
Character Set Support……Page 127
3 Datatypes……Page 129
Oracle Datatypes……Page 130
Internal Datatypes……Page 132
LONG, RAW, LONG RAW, VARCHAR2……Page 133
UROWID……Page 134
External Datatypes……Page 135
VARCHAR2……Page 137
NUMBER……Page 139
FLOAT……Page 140
STRING……Page 141
VARCHAR……Page 142
DATE……Page 143
VARRAW……Page 144
CHAR……Page 145
Named Data Types (Object, VARRAY, Nested Table)……Page 147
ROWID Descriptor……Page 148
LOB Descriptor……Page 149
Datetime and Interval Datatype Descriptors……Page 151
Data Conversions……Page 154
Data Conversions for LOB Datatype Descriptors……Page 156
Data Conversions for Datetime and Interval Datatypes……Page 157
Datetime and Date Migration Rules……Page 158
Typecodes……Page 159
Relationship Between SQLT and OCI_TYPECODE Values……Page 161
Definitions in oratypes.h……Page 163
4 Using SQL Statements in OCI……Page 175
Processing SQL Statements……Page 176
Preparing Statements……Page 178
Using Prepared Statements on Multiple Servers……Page 179
What is Binding?……Page 180
Execution Snapshots……Page 181
Execution Modes……Page 182
Batch Error Mode for OCIStmtExecute()……Page 183
Describing Select-List Items……Page 186
Implicit Describe……Page 187
Explicit Describe of Queries……Page 188
What is Defining?……Page 189
Fetching Results……Page 190
Setting Prefetch Count……Page 191
Support for Scrollable Cursors in OCI……Page 192
Example of Access on a Scrollable Cursor……Page 193
5 Binding and Defining……Page 195
Binding……Page 196
Named Binds and Positional Binds……Page 198
Binding Placeholders in PL/SQL……Page 199
Steps Used in Binding……Page 200
PL/SQL Example……Page 202
Binding REFs……Page 204
Binding LOBs……Page 205
Binding Ref Cursor Variables……Page 211
Summary of Bind Information……Page 212
Defining……Page 213
Steps Used in Defining……Page 214
Advanced Defines……Page 215
Defining LOB Output Variables……Page 216
Defining For a Piecewise Fetch……Page 219
Binding and Defining Arrays of Structures……Page 220
Skip Parameters……Page 221
Arrays of Structures and Indicator Variables……Page 223
Using DML with RETURNING Clause……Page 224
Binding RETURNING…INTO variables……Page 225
DML with RETURNING REF…INTO clause……Page 226
Array Interface for DML RETURNING Statements……Page 228
Choosing Character Set……Page 229
Using OCI_ATTR_MAXDATA_SIZE Attribute……Page 230
Using OCI_ATTR_MAXCHAR_SIZE Attribute……Page 231
Buffer Expansion During Binding……Page 232
Constraint Checking During Defining……Page 233
Code Examples for Binding and Defining with Character Conversion……Page 234
PL/SQL REF CURSORs and Nested Tables……Page 237
Valid Datatypes for Piecewise Operations……Page 238
Binding and Defining for LOBs……Page 239
Types of Piecewise Operations……Page 240
Providing INSERT or UPDATE Data at Runtime……Page 241
Providing FETCH Information at Runtime……Page 244
Additional Information About Piecewise Operations with No Callbacks……Page 247
6 Describing Schema Metadata……Page 249
Using OCIDescribeAny()……Page 250
Notes on Types and Attributes……Page 252
Parameter Attributes……Page 253
Procedure/Function/Subprogram Attributes……Page 255
Type Attributes……Page 256
Type Attribute Attributes……Page 258
Type Method Attributes……Page 259
Collection Attributes……Page 260
Sequence Attributes……Page 262
Column Attributes……Page 263
Argument/Result Attributes……Page 264
List Attributes……Page 266
Database Attributes……Page 267
Character Length Semantics Support in Describing……Page 269
Retrieving Column Data Types For a Table……Page 271
Describing the Stored Procedure……Page 272
Retrieving Attributes of an Object Type……Page 274
Retrieving the Collection Element’s Data Type of a Named Collection Type……Page 277
Describing with Character Length Semantics……Page 278
7 LOB and FILE Operations……Page 281
Creating and Modifying Internal LOBs……Page 282
LOB Attributes of an Object……Page 283
Array Interface For LOBs……Page 284
LOB and FILE Functions……Page 285
Functions for Improving LOB Read/Write Performance……Page 291
Functions for Opening and Closing LOBs……Page 292
LOB Read and Write Callbacks……Page 294
Reading LOBs using Callbacks……Page 295
Writing LOBs using Callbacks……Page 296
Temporary LOB Support……Page 298
Temporary LOB Durations……Page 299
Temporary LOB Example……Page 300
8 Managing Scalable Platforms……Page 307
Levels of Transactional Complexity……Page 308
Transaction Examples……Page 315
Password and Session Management……Page 317
Authentication Management……Page 318
Password Management……Page 319
Session Management……Page 320
Middle-tier Applications……Page 321
Attributes for Middle-tier Applications……Page 322
Middle-tier Example……Page 324
Attributes for Authentication……Page 327
OCI Attributes for Externally Initialized Context……Page 328
Using OCISessionBegin() with an Externally initialized Context……Page 329
Oracle9i Application Server Cache……Page 332
9 OCI Programming Advanced Topics……Page 335
Thread Safety and Three-Tier Architectures……Page 336
Implementing Thread Safety……Page 337
Multithreading Example……Page 338
The OCIThread Package……Page 339
Initialization and Termination……Page 340
Passive Threading Primitives……Page 341
Active Threading Primitives……Page 344
Example Using OCIThread……Page 345
OCI Connection Pooling Concepts……Page 348
OCI Calls for Connection Pooling……Page 350
Example of Connection Pooling……Page 354
Registering User Callbacks……Page 358
OCI Callbacks From External Procedures……Page 368
Failover Callback Structure and Parameters……Page 369
Failover Callback Example……Page 371
Handling OCI_FO_ERROR……Page 373
OCI Advanced Queuing Descriptors……Page 376
Advanced Queuing in OCI vs. PL/SQL……Page 377
Publish-Subscribe Notification……Page 380
Publish-Subscribe Registration Functions……Page 381
Notification Callback……Page 386
Notification Procedure……Page 387
Publish-Subscribe Direct Registration Example……Page 388
Publish-Subscribe LDAP Registration Example……Page 393
Part II OCI Object Concepts……Page 397
10 OCI Object-Relational Programming……Page 399
OCI Object Overview……Page 400
Basic Object Program Structure……Page 402
Persistent Objects, Transient Objects, and Values……Page 404
Representing Objects in C Applications……Page 406
Initializing Environment and Object Cache……Page 408
Retrieving an Object Reference from the Server……Page 409
Pinning an Object……Page 410
Manipulating Object Attributes……Page 412
Marking Objects and Flushing Changes……Page 413
Fetching Embedded Objects……Page 414
Object Meta-Attributes……Page 416
Complex Object Retrieval……Page 420
COR Prefetching……Page 424
OCI Versus SQL Access to Objects……Page 426
Nullity……Page 428
Creating Objects……Page 431
Object Reference and Type Reference……Page 433
Creating Objects Based on Object Views or User-defined OIDs……Page 434
Type Inheritance……Page 435
Substitutability……Page 436
NOT INSTANTIABLE Types and Methods……Page 437
OCI Support for Type Inheritance……Page 438
OTT Support for Type Inheritance……Page 439
Type Evolution……Page 440
11 Object-Relational Datatypes……Page 441
Mapping Oracle Datatypes to C……Page 442
Manipulating C Datatypes With OCI……Page 444
Date Conversion Functions……Page 446
Date Validity Checking Functions……Page 447
Date Example……Page 448
Datetime and Interval (OCIDateTime, OCIInterval)……Page 449
Datetime Functions……Page 450
Datetime Example……Page 452
Interval Functions……Page 453
Number Arithmetic Functions……Page 454
Exponential and Logarithmic Functions……Page 455
Number Assignment, Comparison, and Evaluation Functions……Page 456
Number Example……Page 457
String Example……Page 459
Raw Functions……Page 460
Collections (OCITable, OCIArray, OCIColl, OCIIter)……Page 461
Collection Data Manipulation Functions……Page 462
Varray/Collection Iterator Example……Page 463
Nested Table Manipulation Functions……Page 464
Nested Table Locators……Page 465
Multilevel Collection Type Example……Page 466
REF (OCIRef)……Page 467
REF Example……Page 468
Any Type, AnyData and AnyDataSet Interfaces……Page 469
Type Interfaces……Page 470
OCIAnyDataSet Interfaces……Page 474
Named Datatype Binds……Page 476
Information for Named Datatype and REF Binds……Page 477
Defining Named Datatype Output Variables……Page 478
Information for Named Datatype and REF Defines, and PL/SQL OUT Binds……Page 479
Binding And Defining Oracle C Datatypes……Page 481
Bind and Define Examples……Page 483
Salary Update Examples……Page 485
Bind Example……Page 488
Define Example……Page 489
12 Direct Path Loading……Page 491
Direct Path Loading Overview……Page 492
Datatypes Supported for Direct Path Loading……Page 493
Direct Path Handles……Page 494
Direct Path Interface Functions……Page 497
Direct Path Load Example for Scalar Columns……Page 499
Direct Path Loading of Object Types……Page 504
Direct Path Loading of Nested Tables……Page 505
Direct Path Loading of Column Objects……Page 506
Direct Path Loading of SQL String Columns……Page 509
Direct Path Loading of REF Columns……Page 512
NOT FINAL Object and REF Columns……Page 516
Direct Path Loading of Object Tables……Page 518
Direct Path Loading a NOT FINAL Object Table……Page 519
Direct Path Loading in Pieces……Page 520
Loading Object Types in Pieces……Page 521
Direct Path Function Context and Attributes……Page 522
Direct Path Column Parameter Attributes……Page 526
Direct Path Function Column Array Handle for Non-scalar Columns……Page 529
13 Object Cache and Object Navigation……Page 531
The Object Cache and Memory Management……Page 532
Cache Consistency and Coherency……Page 534
Object Cache Parameters……Page 535
Object Cache Operations……Page 536
Loading and Removing Object Copies……Page 537
Making Changes to Object Copies……Page 539
Synchronizing Object Copies with Server……Page 540
Object Locking……Page 542
Object Duration……Page 545
Memory Layout of an Instance……Page 547
Simple Object Navigation……Page 548
Pin/Unpin/Free Functions……Page 550
Object Meta-Attribute Accessor Functions……Page 551
Type Evolution and the Object Cache……Page 552
14 The Object Type Translator (OTT)……Page 553
What is the Object Type Translator……Page 554
Invoking OTT……Page 557
OTT Command Line Invocation Example……Page 558
The Intype File……Page 561
OTT Datatype Mappings……Page 562
Mapping Object Datatypes to C……Page 564
OTT Type Mapping Example……Page 565
Null Indicator Structs……Page 568
OTT Support for Type Inheritance……Page 569
The Outtype File……Page 573
Using OTT with OCI Applications……Page 574
Accessing and Manipulating Objects with OCI……Page 575
Calling the Initialization Function……Page 576
OTT Reference……Page 578
OTT Command Line Syntax……Page 579
OTT Parameters……Page 580
Where OTT Parameters Can Appear……Page 585
Structure of the Intype File……Page 586
Nested Included File Generation……Page 588
SCHEMA_NAMES Usage……Page 590
Default Name Mapping……Page 592
OTT Restriction on File Name Comparison……Page 594
Part III Part III OCI Reference……Page 595
15 OCI Relational Functions……Page 597
Function Syntax……Page 598
Server Round-trips for LOB Functions……Page 599
Connect, Authorize, and Initialize Functions……Page 600
OCIConnectionPoolCreate()……Page 601
OCIConnectionPoolDestroy()……Page 604
OCIEnvCreate()……Page 605
OCIEnvInit()……Page 608
OCIInitialize()……Page 610
OCILogoff()……Page 613
OCILogon()……Page 614
OCILogon2()……Page 616
OCIServerAttach()……Page 618
OCIServerDetach()……Page 621
OCISessionBegin()……Page 622
OCISessionEnd()……Page 626
OCITerminate()……Page 627
Handle and Descriptor Functions……Page 628
OCIAttrGet()……Page 629
OCIAttrSet()……Page 631
OCIDescriptorAlloc()……Page 633
OCIDescriptorFree()……Page 635
OCIHandleAlloc()……Page 637
OCIHandleFree()……Page 640
OCIParamGet()……Page 642
OCIParamSet()……Page 644
Bind, Define, and Describe Functions……Page 646
OCIBindArrayOfStruct()……Page 647
OCIBindByName()……Page 648
OCIBindByPos()……Page 653
OCIBindDynamic()……Page 658
OCIBindObject()……Page 662
OCIDefineArrayOfStruct()……Page 664
OCIDefineByPos()……Page 665
OCIDefineDynamic()……Page 669
OCIDefineObject……Page 672
OCIDescribeAny()……Page 674
OCIStmtGetBindInfo()……Page 677
Statement Functions……Page 679
OCIStmtExecute()……Page 680
OCIStmtFetch()……Page 683
OCIStmtFetch2()……Page 685
OCIStmtGetPieceInfo()……Page 688
OCIStmtPrepare()……Page 690
OCIStmtSetPieceInfo()……Page 692
16 More OCI Relational Functions……Page 695
Function Syntax……Page 696
Server Round-trips for LOB Functions……Page 697
LOB Functions……Page 698
OCIDurationBegin()……Page 701
OCIDurationEnd()……Page 703
OCILobAppend()……Page 704
OCILobAssign()……Page 706
OCILobCharSetForm()……Page 708
OCILobCharSetId()……Page 709
OCILobClose()……Page 710
OCILobCopy()……Page 712
OCILobCreateTemporary()……Page 714
OCILobDisableBuffering()……Page 716
OCILobEnableBuffering()……Page 717
OCILobErase()……Page 718
OCILobFileClose()……Page 720
OCILobFileCloseAll()……Page 721
OCILobFileExists()……Page 722
OCILobFileGetName()……Page 723
OCILobFileIsOpen()……Page 725
OCILobFileOpen()……Page 726
OCILobFileSetName()……Page 727
OCILobFlushBuffer()……Page 729
OCILobFreeTemporary()……Page 731
OCILobGetChunkSize()……Page 732
OCILobGetLength()……Page 734
OCILobIsEqual()……Page 736
OCILobIsOpen()……Page 737
OCILobIsTemporary()……Page 739
OCILobLoadFromFile()……Page 740
OCILobLocatorAssign()……Page 742
OCILobLocatorIsInit()……Page 744
OCILobOpen()……Page 746
OCILobRead()……Page 748
OCILobTrim()……Page 753
OCILobWrite()……Page 755
OCILobWriteAppend()……Page 760
Advanced Queuing and Publish-Subscribe Functions……Page 764
OCIAQDeq()……Page 765
OCIAQEnq()……Page 767
Example 1 – Enqueue And Dequeue Of A Payload Object…….Page 768
Example 2 – Enqueue and Dequeue Using Correlation Ids…….Page 770
Example 3 – Enqueue and Dequeue Of A Raw Queue…….Page 773
Example 4 – Enqueue and Dequeue Using OCIAQAgent…….Page 774
OCIAQListen()……Page 779
OCISubscriptionDisable()……Page 781
OCISubscriptionEnable()……Page 782
OCISubscriptionPost()……Page 783
OCISubscriptionRegister()……Page 785
OCISubscriptionUnRegister()……Page 788
Direct Path Loading Functions……Page 790
OCIDirPathAbort()……Page 791
OCIDirPathColArrayEntryGet()……Page 792
OCIDirPathColArrayEntrySet()……Page 794
OCIDirPathColArrayRowGet()……Page 796
OCIDirPathColArrayReset()……Page 798
OCIDirPathColArrayToStream()……Page 799
OCIDirPathDataSave()……Page 801
OCIDirPathFinish()……Page 802
OCIDirPathFlushRow()……Page 803
OCIDirPathLoadStream()……Page 804
OCIDirPathPrepare()……Page 806
OCIDirPathStreamReset()……Page 807
Thread Management Functions……Page 808
OCIThreadClose()……Page 810
OCIThreadCreate()……Page 811
OCIThreadHandleGet()……Page 813
OCIThreadHndDestroy()……Page 814
OCIThreadHndInit()……Page 815
OCIThreadIdDestroy()……Page 816
OCIThreadIdGet()……Page 817
OCIThreadIdInit()……Page 818
OCIThreadIdNull()……Page 819
OCIThreadIdSame()……Page 820
OCIThreadIdSet()……Page 821
OCIThreadIdSetNull()……Page 822
OCIThreadInit()……Page 823
OCIThreadIsMulti()……Page 824
OCIThreadJoin()……Page 825
OCIThreadKeyDestroy()……Page 826
OCIThreadKeyGet()……Page 827
OCIThreadKeyInit()……Page 828
OCIThreadKeySet()……Page 829
OCIThreadMutexAcquire()……Page 830
OCIThreadMutexDestroy()……Page 831
OCIThreadMutexInit()……Page 832
OCIThreadMutexRelease()……Page 833
OCIThreadProcessInit()……Page 834
OCIThreadTerm()……Page 835
Transaction Functions……Page 836
OCITransCommit()……Page 837
OCITransDetach()……Page 840
OCITransForget()……Page 841
OCITransMultiPrepare()……Page 842
OCITransPrepare()……Page 843
OCITransRollback()……Page 844
OCITransStart()……Page 845
Miscellaneous Functions……Page 853
OCIBreak()……Page 854
OCIErrorGet()……Page 855
OCILdaToSvcCtx()……Page 857
OCIPasswordChange()……Page 859
OCIReset()……Page 861
OCIRowidToChar()……Page 862
OCIServerVersion()……Page 863
OCISvcCtxToLda()……Page 864
OCIUserCallbackGet()……Page 865
OCIUserCallbackRegister()……Page 867
17 OCI Navigational and Type Functions……Page 873
Object Types and Lifetimes……Page 874
Terminology……Page 875
The Function Syntax……Page 876
Navigational Function Error Codes……Page 877
OCI Flush or Refresh Functions……Page 880
OCICacheFlush()……Page 881
OCICacheRefresh()……Page 883
OCIObjectFlush()……Page 885
OCIObjectRefresh()……Page 886
OCI Mark or Unmark Object and Cache Functions……Page 888
OCICacheUnmark()……Page 889
For Values……Page 890
For Transient Objects……Page 891
For Values……Page 892
For Values……Page 894
For Values……Page 895
OCI Get Object Status Functions……Page 896
OCIObjectExists()……Page 897
OCIObjectGetProperty()……Page 898
OCIObjectIsDirty()……Page 902
OCIObjectIsLocked()……Page 903
OCI Miscellaneous Object Functions……Page 904
OCIObjectCopy()……Page 905
OCIObjectGetAttr()……Page 907
OCIObjectGetInd()……Page 909
OCIObjectGetObjectRef()……Page 910
OCIObjectGetTypeRef()……Page 911
OCIObjectLock()……Page 912
OCIObjectLockNoWait()……Page 913
OCIObjectNew()……Page 915
For Values……Page 917
OCIObjectSetAttr()……Page 919
OCI Pin, Unpin, and Free Functions……Page 921
OCICacheFree()……Page 922
OCICacheUnpin()……Page 923
OCIObjectArrayPin()……Page 924
For Persistent Objects……Page 926
For Values……Page 927
OCIObjectPin()……Page 928
For Persistent Objects……Page 929
For Transient Objects……Page 930
For Values……Page 931
OCIObjectPinTable()……Page 933
OCIObjectUnpin()……Page 935
For Values……Page 936
OCI Type Information Accessor Functions……Page 937
OCITypeArrayByName()……Page 938
OCITypeArrayByRef()……Page 941
OCITypeByName()……Page 943
OCITypeByRef()……Page 946
18 OCI Datatype Mapping and Manipulation Functions……Page 947
The Function Syntax……Page 948
Functions Returning Other Values……Page 949
Examples……Page 950
OCI Collection and Iterator Functions……Page 951
OCICollAppend()……Page 952
OCICollAssign()……Page 954
OCICollAssignElem()……Page 956
OCICollGetElem()……Page 958
OCICollIsLocator()……Page 961
OCICollMax()……Page 962
OCICollSize()……Page 963
OCICollTrim()……Page 965
OCIIterCreate()……Page 966
OCIIterDelete()……Page 967
OCIIterGetCurrent()……Page 968
OCIIterInit()……Page 969
OCIIterNext()……Page 970
OCIIterPrev()……Page 972
OCI Date, Datetime, and Interval Functions……Page 974
OCIDateAddDays()……Page 977
OCIDateAddMonths()……Page 978
OCIDateAssign()……Page 979
OCIDateCheck()……Page 980
OCIDateCompare()……Page 982
OCIDateDaysBetween()……Page 983
OCIDateFromText()……Page 984
OCIDateGetDate()……Page 986
OCIDateGetTime()……Page 987
OCIDateLastDay()……Page 988
OCIDateNextDay()……Page 989
OCIDateSetDate()……Page 990
OCIDateSetTime()……Page 991
OCIDateSysDate()……Page 992
OCIDateToText()……Page 993
OCIDateTimeAssign()……Page 995
OCIDateTimeCheck()……Page 996
OCIDateTimeCompare()……Page 998
OCIDateTimeConstruct()……Page 999
OCIDateTimeConvert()……Page 1001
OCIDateTimeFromArray()……Page 1002
OCIDateTimeFromText()……Page 1004
OCIDateTimeGetDate()……Page 1006
OCIDateTimeGetTime()……Page 1007
OCIDateTimeGetTimeZoneName()……Page 1009
OCIDateTimeGetTimeZoneOffset()……Page 1010
OCIDateTimeIntervalAdd()……Page 1011
OCIDateTimeIntervalSub()……Page 1012
OCIDateTimeSubtract()……Page 1013
OCIDateTimeSysTimeStamp()……Page 1014
OCIDateTimeToArray()……Page 1015
OCIDateTimeToText()……Page 1017
OCIDateZoneToZone()……Page 1019
OCIIntervalAdd()……Page 1021
OCIIntervalAssign()……Page 1022
OCIIntervalCheck()……Page 1023
OCIIntervalCompare()……Page 1025
OCIIntervalDivide()……Page 1027
OCIIntervalFromNumber()……Page 1028
OCIIntervalFromText()……Page 1029
OCIIntervalFromTZ()……Page 1031
OCIIntervalGetDaySecond()……Page 1032
OCIIntervalGetYearMonth()……Page 1034
OCIIntervalMultiply()……Page 1035
OCIIntervalSetDaySecond()……Page 1036
OCIIntervalSetYearMonth()……Page 1038
OCIIntervalSubtract()……Page 1039
OCIIntervalToNumber()……Page 1040
OCIIntervalToText()……Page 1041
OCI Number Functions……Page 1043
OCINumberAbs()……Page 1045
OCINumberAdd()……Page 1046
OCINumberArcCos()……Page 1047
OCINumberArcSin()……Page 1048
OCINumberArcTan()……Page 1049
OCINumberArcTan2()……Page 1050
OCINumberAssign()……Page 1051
OCINumberCeil()……Page 1052
OCINumberCmp()……Page 1053
OCINumberCos()……Page 1054
OCINumberDec()……Page 1055
OCINumberDiv()……Page 1056
OCINumberExp()……Page 1057
OCINumberFloor()……Page 1058
OCINumberFromInt()……Page 1059
OCINumberFromReal()……Page 1060
OCINumberFromText()……Page 1061
OCINumberHypCos()……Page 1063
OCINumberHypSin()……Page 1064
OCINumberHypTan()……Page 1065
OCINumberInc()……Page 1066
OCINumberIntPower()……Page 1067
OCINumberIsInt()……Page 1068
OCINumberIsZero()……Page 1069
OCINumberLn()……Page 1070
OCINumberLog()……Page 1071
OCINumberMod()……Page 1072
OCINumberMul()……Page 1073
OCINumberNeg()……Page 1074
OCINumberPower()……Page 1075
OCINumberPrec()……Page 1076
OCINumberRound()……Page 1077
OCINumberSetPi()……Page 1078
OCINumberSetZero()……Page 1079
OCINumberShift()……Page 1080
OCINumberSign()……Page 1081
OCINumberSin()……Page 1082
OCINumberSqrt()……Page 1083
OCINumberSub()……Page 1084
OCINumberTan()……Page 1085
OCINumberToInt()……Page 1086
OCINumberToReal()……Page 1087
OCINumberToText()……Page 1088
OCINumberTrunc()……Page 1090
OCI Raw Functions……Page 1091
OCIRawAllocSize()……Page 1092
OCIRawAssignBytes()……Page 1093
OCIRawAssignRaw()……Page 1094
OCIRawPtr()……Page 1095
OCIRawResize()……Page 1096
OCIRawSize()……Page 1097
OCI Ref Functions……Page 1098
OCIRefAssign()……Page 1099
OCIRefClear()……Page 1100
OCIRefFromHex()……Page 1101
OCIRefHexSize()……Page 1103
OCIRefIsEqual()……Page 1104
OCIRefIsNull()……Page 1105
OCIRefToHex()……Page 1106
OCI String Functions……Page 1107
OCIStringAllocSize()……Page 1108
OCIStringAssign()……Page 1109
OCIStringAssignText()……Page 1110
OCIStringGetEncoding()……Page 1111
OCIStringPtr()……Page 1112
OCIStringResize()……Page 1113
OCIStringSize()……Page 1114
OCI Table Functions……Page 1115
OCITableDelete()……Page 1116
OCITableExists()……Page 1117
OCITableFirst()……Page 1118
OCITableLast()……Page 1119
OCITableNext()……Page 1120
OCITablePrev()……Page 1122
OCITableSize()……Page 1124
19 OCI Cartridge Functions……Page 1127
The Function Syntax……Page 1128
With_Context Type……Page 1129
Cartridge Services — OCI External Procedures……Page 1130
OCIExtProcAllocCallMemory()……Page 1131
OCIExtProcRaiseExcp()……Page 1132
OCIExtProcRaiseExcpWithMsg()……Page 1133
OCIExtProcGetEnv()……Page 1134
Cartridge Services — Memory Services……Page 1135
OCIDurationBegin()……Page 1136
OCIDurationEnd()……Page 1137
OCIMemoryAlloc()……Page 1138
OCIMemoryResize()……Page 1140
OCIMemoryFree()……Page 1141
Cartridge Services — Maintaining Context……Page 1142
OCIContextSetValue()……Page 1143
OCIContextGetValue()……Page 1145
OCIContextClearValue()……Page 1146
OCIContextGenerateKey()……Page 1147
Cartridge Services — Parameter Manager Interface……Page 1148
OCIExtractInit()……Page 1149
OCIExtractTerm()……Page 1150
OCIExtractReset()……Page 1151
OCIExtractSetNumKeys()……Page 1152
OCIExtractSetKey()……Page 1153
OCIExtractFromFile()……Page 1155
OCIExtractFromStr()……Page 1156
OCIExtractToInt()……Page 1157
OCIExtractToBool()……Page 1158
OCIExtractToStr()……Page 1159
OCIExtractToOCINum()……Page 1161
OCIExtractToList()……Page 1162
OCIExtractFromList()……Page 1163
OCIFileObject……Page 1165
OCIFileInit()……Page 1166
OCIFileTerm()……Page 1167
OCIFileOpen()……Page 1168
OCIFileClose()……Page 1170
OCIFileRead()……Page 1171
OCIFileWrite()……Page 1173
OCIFileSeek()……Page 1174
OCIFileExists()……Page 1176
OCIFileGetLength()……Page 1177
OCIFileFlush()……Page 1178
Cartridge Services — String Formatting Interface……Page 1179
OCIFormatInit()……Page 1180
OCIFormatTerm()……Page 1181
OCIFormatString()……Page 1182
Format Modifiers……Page 1185
Format Codes……Page 1187
Example……Page 1189
20 OCI Any Type and Data Functions……Page 1191
Function Return Values……Page 1192
OCI Type Interface Functions……Page 1194
OCITypeAddAttr()……Page 1195
OCITypeBeginCreate()……Page 1196
OCITypeEndCreate()……Page 1198
OCITypeSetBuiltin()……Page 1199
OCITypeSetCollection()……Page 1200
OCI Any Data Interface Functions……Page 1201
OCIAnyDataAccess()……Page 1202
OCIAnyDataAttrGet()……Page 1204
OCIAnyDataAttrSet()……Page 1207
OCIAnyDataBeginCreate()……Page 1210
OCIAnyDataCollAddElem()……Page 1212
OCIAnyDataCollGetElem()……Page 1214
OCIAnyDataConvert()……Page 1216
OCIAnyDataDestroy()……Page 1218
OCIAnyDataEndCreate()……Page 1219
OCIAnyDataGetCurrAttrNum()……Page 1220
OCIAnyDataGetType()……Page 1221
OCIAnyDataIsNull()……Page 1222
OCI Any Data Set Interface Functions……Page 1223
OCIAnyDataSetAddInstance()……Page 1224
OCIAnyDataSetBeginCreate()……Page 1226
OCIAnyDataSetDestroy()……Page 1228
OCIAnyDataSetEndCreate()……Page 1229
OCIAnyDataSetGetCount()……Page 1230
OCIAnyDataSetGetInstance()……Page 1231
OCIAnyDataSetGetType()……Page 1232
Part IV Appendixes……Page 1233
A Handle and Descriptor Attributes……Page 1235
Conventions……Page 1237
OCI_ATTR_CACHE_MAX_SIZE……Page 1238
OCI_ATTR_ENV_NCHARSET_ID……Page 1239
OCI_ATTR_LDAP_CRED……Page 1240
OCI_ATTR_OBJECT……Page 1241
OCI_ATTR_HEAPALLOC……Page 1242
OCI_ATTR_SHARED_HEAP_ALLOC……Page 1243
OCI_ATTR_WALL_LOC……Page 1244
OCI_ATTR_DML_ROW_OFFSET……Page 1245
OCI_ATTR_SERVER……Page 1246
OCI_ATTR_TRANS……Page 1247
OCI_ATTR_FOCBK……Page 1248
OCI_ATTR_NONBLOCKING_MODE……Page 1249
OCI_ATTR_SERVER_STATUS……Page 1250
OCI_ATTR_APPCTX_SIZE……Page 1251
OCI_ATTR_CLIENT_IDENTIFIER……Page 1252
OCI_ATTR_MIGSESSION……Page 1253
OCI_ATTR_USERNAME……Page 1254
OCI_ATTR_CONN_BUSY_COUNT……Page 1255
OCI_ATTR_CONN_INCR……Page 1256
OCI_ATTR_XID……Page 1257
OCI_ATTR_PARAM_COUNT……Page 1258
OCI_ATTR_PREFETCH_MEMORY……Page 1259
OCI_ATTR_ROWID……Page 1260
OCI_ATTR_SQLFNCODE……Page 1261
OCI_ATTR_STATEMENT……Page 1263
OCI_ATTR_STMT_TYPE……Page 1264
OCI_ATTR_CHARSET_ID……Page 1266
OCI_ATTR_PDPRC……Page 1267
OCI_ATTR_ROWS_RETURNED……Page 1268
OCI_ATTR_CHARSET_ID……Page 1269
OCI_ATTR_PDPRC……Page 1270
OCI_ATTR_PDSCL……Page 1271
Parameter Descriptor Attributes……Page 1272
OCI_ATTR_LOBEMPTY……Page 1273
OCI_ATTR_COMPLEXOBJECTCOMP_TYPE……Page 1274
OCI_ATTR_COMPLEXOBJECTCOMP_TYPE_LEVEL……Page 1275
OCI_ATTR_SEQUENCE_DEVIATION……Page 1276
OCI_ATTR_CORRELATION……Page 1277
OCI_ATTR_DEQ_MSGID……Page 1278
OCI_ATTR_VISIBILITY……Page 1279
OCI_ATTR_CORRELATION……Page 1280
OCI_ATTR_ENQ_TIME……Page 1281
OCI_ATTR_EXPIRATION……Page 1282
OCI_ATTR_RECIPIENT_LIST……Page 1283
OCI_ATTR_AGENT_ADDRESS……Page 1284
OCI_ATTR_DN_COUNT……Page 1285
OCI_ATTR_SERVER_DN……Page 1286
OCI_ATTR_SUBSCR_CTX……Page 1287
OCI_ATTR_SUBSCR_PAYLOAD……Page 1288
OCI_ATTR_SUBSCR_RECPTPRES……Page 1289
OCI_ATTR_SUBSCR_RECPTPROTO……Page 1290
OCI_ATTR_DATEFORMAT……Page 1292
OCI_ATTR_DIRPATH_OBJ_CONSTR……Page 1293
OCI_ATTR_NAME……Page 1294
OCI_ATTR_SUB_NAME……Page 1295
OCI_ATTR_LIST_COLUMNS……Page 1296
Direct Path and Direct Path Function Column Array Handle (OCIDirPathColArray) Attributes……Page 1297
OCI_ATTR_ROW_COUNT……Page 1298
OCI_ATTR_STREAM_OFFSET……Page 1299
Direct Path Column Parameter Attributes……Page 1300
OCI_ATTR_DATA_SIZE……Page 1302
OCI_ATTR_DIRPATH_OID……Page 1303
OCI_ATTR_SCALE……Page 1304
OCI_ATTR_MEMPOOL_HOMENAME……Page 1306
OCI_ATTR_PROC_MODE……Page 1307
B OCI Demonstration Programs……Page 1309
C OCI Function Server Round-trips……Page 1313
Relational Function Round-trips……Page 1314
LOB Function Round-trips……Page 1315
Object and Cache Function Round-trips……Page 1316
Datatype Mapping and Manipulation Function Round-trips……Page 1318
Other Local Functions……Page 1319
Index……Page 1321
Reviews
There are no reviews yet.