245a2b450e1144324fbddf0a55aa3ab200b7dd65
[clsql.git] / db-oracle / oracle-constants.cl
1 ;;; -*- Mode: Lisp -*-
2 ;;; $Id: oracle-constants.cl,v 1.1 2002/09/18 07:43:41 kevin Exp $
3
4 (in-package :clsql-oracle)
5
6 (defconstant +oci-default+      #x00)   ; default value for parameters and attributes
7 (defconstant +oci-threaded+     #x01)   ; application is in threaded environment
8 (defconstant +oci-object+       #x02)   ; the application is in object environment
9 (defconstant +oci-non-blocking+ #x04)   ; non blocking mode of operation
10 (defconstant +oci-env-no-mutex+ #x08)   ; the environment handle will not be protected by a mutex internally
11
12 ;; Handle types
13
14 (defconstant +oci-htype-env+    1)      ; environment handle
15 (defconstant +oci-htype-error+  2)      ; error handle
16 (defconstant +oci-htype-svcctx+ 3)      ; service handle
17 (defconstant +oci-htype-stmt+   4)      ; statement handle
18 (defconstant +oci-htype-bind+   5)      ; bind handle
19 (defconstant +oci-htype-define+ 6)      ; define handle
20 (defconstant +oci-htype-describe+ 7)    ; describe handle
21 (defconstant +oci-htype-server+ 8)      ; server handle
22 (defconstant +oci-htype-session+ 9)     ; authentication handle
23 (defconstant +oci-htype-trans+  10)     ; transaction handle
24 (defconstant +oci-htype-complexobject+ 11) ; complex object retrieval handle
25 (defconstant +oci-htype-security+ 12)   ; security handle
26
27 ;; Descriptor types
28
29 (defconstant +oci-dtype-lob+               50) ; lob locator
30 (defconstant +oci-dtype-snap+              51) ; snapshot
31 (defconstant +oci-dtype-rset+              52) ; result set
32 (defconstant +oci-dtype-param+             53) ; parameter descriptor obtained from ocigparm
33 (defconstant +oci-dtype-rowid+             54) ; rowid
34 (defconstant +oci-dtype-complexobjectcomp+ 55) ; complex object retrieval descriptor
35 (defconstant +oci-dtype-file+              56) ; File Lob locator
36 (defconstant +oci-dtype-aqenq-options+     57) ; enqueue options
37 (defconstant +oci-dtype-aqdeq-options+     58) ; dequeue options
38 (defconstant +oci-dtype-aqmsg-properties+  59) ; message properties
39 (defconstant +oci-dtype-aqagent+           60) ; aq agent
40
41 ;; Objectr pointer types
42
43 (defconstant +oci-otype-name+   1)      ; object name
44 (defconstant +oci-otype-ref+    2)      ; REF to TDO
45 (defconstant +oci-otype-ptr+    3)      ; PTR to TDO
46
47 ;; Attribute types
48
49 (defconstant +oci-attr-fncode+                  1) ; the OCI function code
50 (defconstant +oci-attr-object+                  2) ; is the environment initialized in object mode
51 (defconstant +oci-attr-nonblocking-mode+        3) ; non blocking mode
52 (defconstant +oci-attr-sqlcode+                 4) ; the SQL verb
53 (defconstant +oci-attr-env+                     5) ; the environment handle
54 (defconstant +oci-attr-server+                  6) ; the server handle
55 (defconstant +oci-attr-session+                 7) ; the user session handle
56 (defconstant +oci-attr-trans+                   8) ; the transaction handle
57 (defconstant +oci-attr-row-count+               9) ; the rows processed so far
58 (defconstant +oci-attr-sqlfncode+              10) ; the SQL verb of the statement
59 (defconstant +oci-attr-prefetch-rows+          11) ; sets the number of rows to prefetch
60 (defconstant +oci-attr-nested-prefetch-rows+   12) ; the prefetch rows of nested table
61 (defconstant +oci-attr-prefetch-memory+        13) ; memory limit for rows fetched
62 (defconstant +oci-attr-nested-prefetch-memory+ 14) ; memory limit for nested rows
63 (defconstant +oci-attr-char-count+             15) ; this specifies the bind and define size in characters
64 (defconstant +oci-attr-pdscl+                  16) ; packed decimal scale
65 (defconstant +oci-attr-pdfmt+                  17) ; packed decimal format
66 (defconstant +oci-attr-param-count+            18) ; number of column in the select list
67 (defconstant +oci-attr-rowid+                  19) ; the rowid
68 (defconstant +oci-attr-charset+                20) ; the character set value
69 (defconstant +oci-attr-nchar+                  21) ; NCHAR type
70 (defconstant +oci-attr-username+               22) ; username attribute
71 (defconstant +oci-attr-password+               23) ; password attribute
72 (defconstant +oci-attr-stmt-type+              24) ; statement type
73 (defconstant +oci-attr-internal-name+          25) ; user friendly global name
74 (defconstant +oci-attr-external-name+          26) ; the internal name for global txn
75 (defconstant +oci-attr-xid+                    27) ; XOPEN defined global transaction id
76 (defconstant +oci-attr-trans-lock+             28) ;
77 (defconstant +oci-attr-trans-name+             29) ; string to identify a global transaction
78 (defconstant +oci-attr-heapalloc+              30) ; memory allocated on the heap
79 (defconstant +oci-attr-charset-id+             31) ; Character Set ID
80 (defconstant +oci-attr-charset-form+           32) ; Character Set Form
81 (defconstant +oci-attr-maxdata-size+           33) ; Maximumsize of data on the server
82 (defconstant +oci-attr-cache-opt-size+         34) ; object cache optimal size
83 (defconstant +oci-attr-cache-max-size+         35) ; object cache maximum size percentage
84 (defconstant +oci-attr-pinoption+              36) ; object cache default pin option
85 (defconstant +oci-attr-alloc-duration+         37) ; object cache default allocation duration
86 (defconstant +oci-attr-pin-duration+           38) ; object cache default pin duration
87 (defconstant +oci-attr-fdo+                    39) ; Format Descriptor object attribute
88 (defconstant +oci-attr-postprocessing-callback+ 40) ; Callback to process outbind data
89 (defconstant +oci-attr-postprocessing-context+ 41) ; Callback context to process outbind data
90 (defconstant +oci-attr-rows-returned+          42) ; Number of rows returned in current iter - for Bind handles
91 (defconstant +oci-attr-focbk+                  43) ; Failover Callback attribute
92 (defconstant +oci-attr-in-v8-mode+             44) ; is the server/service context in V8 mode
93 (defconstant +oci-attr-lobempty+               45) ; empty lob ?
94 (defconstant +oci-attr-sesslang+               46) ; session language handle
95
96 ;; AQ Attribute Types
97 ;; Enqueue Options
98
99 (defconstant +oci-attr-visibility+ 47)  ; visibility
100 (defconstant +oci-attr-relative-msgid+ 48) ; relative message id
101 (defconstant +oci-attr-sequence-deviation+ 49) ; sequence deviation
102
103 ; - Dequeue Options -
104     ; consumer name
105 ;#define OCI-ATTR-DEQ-MODE 50
106 ;(defconstant +OCI-ATTR-CONSUMER-NAME           50              + 51)                ; dequeue mode
107 ;#define OCI-ATTR-NAVIGATION            52                     ; navigation
108 ;#define OCI-ATTR-WAIT                  53                           ; wait
109 ;#define OCI-ATTR-DEQ-MSGID             54             ; dequeue message id
110
111 ; - Message Properties -
112 (defconstant +OCI-ATTR-PRIORITY+ 55)    ; priority
113 (defconstant +OCI-ATTR-DELAY+ 56)       ; delay
114 (defconstant +OCI-ATTR-EXPIRATION+ 57)  ; expiration
115 (defconstant +OCI-ATTR-CORRELATION+ 58) ; correlation id
116 (defconstant +OCI-ATTR-ATTEMPTS+ 59)    ; # of attempts
117 (defconstant +OCI-ATTR-RECIPIENT-LIST+ 60) ; recipient list
118 (defconstant +OCI-ATTR-EXCEPTION-QUEUE+ 61) ; exception queue name
119 (defconstant +OCI-ATTR-ENQ-TIME+ 62)    ; enqueue time (only OCIAttrGet)
120 (defconstant +OCI-ATTR-MSG-STATE+ 63)   ; message state (only OCIAttrGet)
121
122 ;; AQ Agent
123 (defconstant +OCI-ATTR-AGENT-NAME+ 64)  ; agent name
124 (defconstant +OCI-ATTR-AGENT-ADDRESS+ 65) ; agent address
125 (defconstant +OCI-ATTR-AGENT-PROTOCOL+ 66) ; agent protocol
126
127 ;- Server handle -
128 (defconstant +OCI-ATTR-NATIVE-FDES+ 67) ; native cncxn file desc
129
130 ;-Parameter Attribute Types-
131
132 (defconstant +OCI-ATTR-UNK+ 101)        ; unknown attribute
133 (defconstant +OCI-ATTR-NUM-COLS+ 102)   ; number of columns
134 (defconstant +OCI-ATTR-LIST-COLUMNS+ 103) ; parameter of the column list
135 (defconstant +OCI-ATTR-RDBA+ 104)       ; DBA of the segment header
136 (defconstant +OCI-ATTR-CLUSTERED+ 105)  ; whether the table is clustered
137 (defconstant +OCI-ATTR-PARTITIONED+ 106) ; whether the table is partitioned
138 (defconstant +OCI-ATTR-INDEX-ONLY+ 107) ; whether the table is index only
139 (defconstant +OCI-ATTR-LIST-ARGUMENTS+ 108) ; parameter of the argument list
140 (defconstant +OCI-ATTR-LIST-SUBPROGRAMS+ 109) ; parameter of the subprogram list
141 (defconstant +OCI-ATTR-REF-TDO+ 110)    ; REF to the type descriptor
142 (defconstant +OCI-ATTR-LINK+ 111)       ; the database link name
143 (defconstant +OCI-ATTR-MIN+ 112)        ; minimum value
144 (defconstant +OCI-ATTR-MAX+ 113)        ; maximum value
145 (defconstant +OCI-ATTR-INCR+ 114)       ; increment value
146 (defconstant +OCI-ATTR-CACHE+ 115)      ; number of sequence numbers cached
147 (defconstant +OCI-ATTR-ORDER+ 116)      ; whether the sequence is ordered
148 (defconstant +OCI-ATTR-HW-MARK+ 117)    ; high-water mark
149 (defconstant +OCI-ATTR-TYPE-SCHEMA+ 118) ; type's schema name
150 (defconstant +OCI-ATTR-TIMESTAMP+ 119)  ; timestamp of the object
151 (defconstant +OCI-ATTR-NUM-ATTRS+ 120)  ; number of sttributes
152 (defconstant +OCI-ATTR-NUM-PARAMS+ 121) ; number of parameters
153 (defconstant +OCI-ATTR-OBJID+ 122)      ; object id for a table or view
154 (defconstant +OCI-ATTR-PTYPE+ 123)      ; type of info described by
155 (defconstant +OCI-ATTR-PARAM+ 124)      ; parameter descriptor
156 (defconstant +OCI-ATTR-OVERLOAD-ID+ 125) ; overload ID for funcs and procs
157 (defconstant +OCI-ATTR-TABLESPACE+ 126) ; table name space
158 (defconstant +OCI-ATTR-TDO+ 127)        ; TDO of a type
159 (defconstant +OCI-ATTR-PARSE-ERROR-OFFSET+ 128) ; Parse Error offset
160 ;-Credential Types-
161 (defconstant +OCI-CRED-RDBMS+ 1)        ; database username/password
162 (defconstant +OCI-CRED-EXT+ 2)          ; externally provided credentials
163
164 ;; Error Return Values-
165
166 (defconstant +oci-continue+             -24200) ; Continue with the body of the OCI function
167 (defconstant +oci-still-executing+       -3123) ; OCI would block error
168 (defconstant +oci-invalid-handle+           -2) ; maps to SQL-INVALID-HANDLE
169 (defconstant +oci-error+                    -1) ; maps to SQL-ERROR
170 (defconstant +oci-success+                   0) ; maps to SQL-SUCCESS of SAG CLI
171 (defconstant +oci-success-with-info+         1) ; maps to SQL-SUCCESS-WITH-INFO
172 (defconstant +oci-need-data+                99) ; maps to SQL-NEED-DATA
173 (defconstant +oci-no-data+                 100) ; maps to SQL-NO-DATA
174
175 ;; Parsing Syntax Types-
176
177 (defconstant +oci-ntv-syntax+ 1)        ; Use what so ever is the native lang of server
178 (defconstant +oci-v7-syntax+ 2)         ; V7 language
179 (defconstant +oci-v8-syntax+ 3)         ; V8 language
180
181 ;-Scrollable Cursor Options-
182
183 (defconstant +oci-fetch-next+           #x02) ; next row
184 (defconstant +oci-fetch-first+          #x04) ; first row of the result set
185 (defconstant +oci-fetch-last+           #x08) ; the last row of the result set
186 (defconstant +oci-fetch-prior+          #x10) ; the previous row relative to current
187 (defconstant +oci-fetch-absolute+       #x20) ; absolute offset from first
188 (defconstant +oci-fetch-relative+       #x40) ; offset relative to current
189
190 ;-Bind and Define Options-
191
192 (defconstant +OCI-SB2-IND-PTR+ #x01)    ; unused
193 (defconstant +OCI-DATA-AT-EXEC+ #x02)   ; data at execute time
194 (defconstant +OCI-DYNAMIC-FETCH+ #x02)  ; fetch dynamically
195 (defconstant +OCI-PIECEWISE+ #x04)      ; piecewise DMLs or fetch
196 ;-
197
198 ;-Execution Modes-
199 (defconstant +OCI-BATCH-MODE+ #x01)     ; batch the oci statement for execution
200 (defconstant +OCI-EXACT-FETCH+ #x02)    ; fetch the exact rows specified
201 (defconstant +OCI-KEEP-FETCH-STATE+ #x04) ; unused
202 (defconstant +OCI-SCROLLABLE-CURSOR+ #x08) ; cursor scrollable
203 (defconstant +OCI-DESCRIBE-ONLY+ #x10)  ; only describe the statement
204 (defconstant +OCI-COMMIT-ON-SUCCESS+ #x20) ; commit, if successful execution
205 ;-
206
207 ;-Authentication Modes-
208 (defconstant +OCI-MIGRATE+ #x0001)      ; migratable auth context
209 (defconstant +OCI-SYSDBA+ #x0002)       ; for SYSDBA authorization
210 (defconstant +OCI-SYSOPER+ #x0004)      ; for SYSOPER authorization
211 (defconstant +OCI-PRELIM-AUTH+ #x0008)  ; for preliminary authorization
212 ;-
213
214 ;-Piece Information-
215 (defconstant +OCI-PARAM-IN+ #x01)       ; in parameter
216 (defconstant +OCI-PARAM-OUT+ #x02)      ; out parameter
217 ;-
218
219 ;- Transaction Start Flags -
220 ; NOTE: OCI-TRANS-JOIN and OCI-TRANS-NOMIGRATE not supported in 8.0.X
221 (defconstant +OCI-TRANS-NEW+ #x00000001) ; starts a new transaction branch
222 (defconstant +OCI-TRANS-JOIN+ #x00000002) ; join an existing transaction
223 (defconstant +OCI-TRANS-RESUME+ #x00000004) ; resume this transaction
224 (defconstant +OCI-TRANS-STARTMASK+ #x000000ff)
225   
226   
227 (defconstant +OCI-TRANS-READONLY+ #x00000100) ; starts a readonly transaction
228 (defconstant +OCI-TRANS-READWRITE+ #x00000200) ; starts a read-write transaction
229 (defconstant +OCI-TRANS-SERIALIZABLE+ #x00000400)
230                                         ; starts a serializable transaction
231 (defconstant +OCI-TRANS-ISOLMASK+ #x0000ff00)
232
233 (defconstant +OCI-TRANS-LOOSE+ #x00010000) ; a loosely coupled branch
234 (defconstant +OCI-TRANS-TIGHT+ #x00020000) ; a tightly coupled branch
235 (defconstant +OCI-TRANS-TYPEMASK+ #x000f0000) ;
236
237 (defconstant +OCI-TRANS-NOMIGRATE+ #x00100000) ; non migratable transaction
238
239 ;-
240
241 ;- Transaction End Flags -
242 (defconstant +OCI-TRANS-TWOPHASE+ #x01000000) ; use two phase commit
243 ;-
244
245 ;; AQ Constants
246 ;; NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE
247 ;; The following constants must match the PL/SQL dbms-aq constants
248 ;; NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE NOTE
249
250 ; - Visibility flags -
251 (defconstant +OCI-ENQ-IMMEDIATE+ 1)     ; enqueue is an independent transaction
252 (defconstant +OCI-ENQ-ON-COMMIT+ 2)     ; enqueue is part of current transaction
253
254 ; - Dequeue mode flags -
255 (defconstant +OCI-DEQ-BROWSE+ 1)        ; read message without acquiring a lock
256 (defconstant +OCI-DEQ-LOCKED+ 2)        ; read and obtain write lock on message
257 (defconstant +OCI-DEQ-REMOVE+ 3)        ; read the message and delete it
258
259 ; - Dequeue navigation flags -
260 (defconstant +OCI-DEQ-FIRST-MSG+ 1)     ; get first message at head of queue
261 (defconstant +OCI-DEQ-NEXT-MSG+ 3)      ; next message that is available
262 (defconstant +OCI-DEQ-NEXT-TRANSACTION+ 2) ; get first message of next txn group
263
264 ; - Message states -
265 (defconstant +OCI-MSG-WAITING+ 1)       ; the message delay has not yet completed
266 (defconstant +OCI-MSG-READY+ 0)         ; the message is ready to be processed
267 (defconstant +OCI-MSG-PROCESSED+ 2)     ; the message has been processed
268 (defconstant +OCI-MSG-EXPIRED+ 3)       ; message has moved to exception queue
269
270 ; - Sequence deviation -
271 (defconstant +OCI-ENQ-BEFORE+ 2)        ; enqueue message before another message
272 (defconstant +OCI-ENQ-TOP+ 3)           ; enqueue message before all messages
273
274 ; - Visibility flags -
275 (defconstant +OCI-DEQ-IMMEDIATE+ 1)     ; dequeue is an independent transaction
276 (defconstant +OCI-DEQ-ON-COMMIT+ 2)     ; dequeue is part of current transaction
277
278 ; - Wait -
279 (defconstant +OCI-DEQ-WAIT-FOREVER+ -1) ; wait forever if no message available
280 (defconstant +OCI-DEQ-NO-WAIT+ 0)       ; do not wait if no message is available
281
282 ; - Delay -
283 (defconstant +OCI-MSG-NO-DELAY+ 0)      ; message is available immediately
284
285 ;; Expiration
286 (defconstant +OCI-MSG-NO-EXPIRATION+ -1) ; message will never expire
287
288 ;; Describe Handle Parameter Attributes
289 ;; Attributes common to Columns and Stored Procs
290
291 (defconstant +oci-attr-data-size+ 1)    ; maximum size of the data
292 (defconstant +oci-attr-data-type+ 2)    ; the sql type of the column/argument
293 (defconstant +oci-attr-disp-size+ 3)    ; the display size
294 (defconstant +oci-attr-name+      4)    ; the name of the column/argument
295 (defconstant +oci-attr-precision+ 5)    ; precision if number type
296 (defconstant +oci-attr-scale+     6)    ; scale if number type
297 (defconstant +oci-attr-is-null+   7)    ; is it null ?
298 (defconstant +oci-attr-type-name+ 8)
299
300 ;; name of the named data type or a package name for package private types
301
302 (defconstant +OCI-ATTR-SCHEMA-NAME+ 9)  ; the schema name
303 (defconstant +OCI-ATTR-SUB-NAME+ 10)    ; type name if package private type
304 (defconstant +OCI-ATTR-POSITION+ 11)    ; relative position of col/arg in the list of cols/args
305
306 ; complex object retrieval parameter attributes
307 (defconstant +OCI-ATTR-COMPLEXOBJECTCOMP-TYPE+ 50) ;
308 (defconstant +OCI-ATTR-COMPLEXOBJECTCOMP-TYPE-LEVEL+ 51) ;
309 (defconstant +OCI-ATTR-COMPLEXOBJECT-LEVEL+ 52) ;
310 (defconstant +OCI-ATTR-COMPLEXOBJECT-COLL-OUTOFLINE+ 53) ;
311
312 ; Only Columns
313 (defconstant +OCI-ATTR-DISP-NAME+ 100)  ; the display name
314
315 ;; stored procs
316
317 (defconstant +OCI-ATTR-OVERLOAD+ 210)   ; is this position overloaded
318 (defconstant +OCI-ATTR-LEVEL+ 211)      ; level for structured types
319 (defconstant +OCI-ATTR-HAS-DEFAULT+ 212) ; has a default value
320 (defconstant +OCI-ATTR-IOMODE+ 213)     ; in, out inout
321 (defconstant +OCI-ATTR-RADIX+ 214)      ; returns a radix
322 (defconstant +OCI-ATTR-NUM-ARGS+ 215)   ; total number of arguments
323
324 ;; named type attributes
325
326 (defconstant +oci-attr-typecode+                216) ; lobject or collection
327 (defconstant +oci-attr-collection-typecode+     217) ; varray or nested table
328 (defconstant +oci-attr-version+                 218) ; user assigned version
329 (defconstant +oci-attr-is-incomplete-type+      219) ; is this an incomplete type
330 (defconstant +oci-attr-is-system-type+          220) ; a system type
331 (defconstant +oci-attr-is-predefined-type+      221) ; a predefined type
332 (defconstant +oci-attr-is-transient-type+       222) ; a transient type
333 (defconstant +oci-attr-is-system-generated-type+ 223) ; system generated type
334 (defconstant +oci-attr-has-nested-table+        224) ; contains nested table attr
335 (defconstant +oci-attr-has-lob+                 225) ; has a lob attribute
336 (defconstant +oci-attr-has-file+                226) ; has a file attribute
337 (defconstant +oci-attr-collection-element+      227) ; has a collection attribute
338 (defconstant +oci-attr-num-type-attrs+          228) ; number of attribute types
339 (defconstant +oci-attr-list-type-attrs+         229) ; list of type attributes
340 (defconstant +oci-attr-num-type-methods+        230) ; number of type methods
341 (defconstant +oci-attr-list-type-methods+       231) ; list of type methods
342 (defconstant +oci-attr-map-method+              232) ; map method of type
343 (defconstant +oci-attr-order-method+            233) ; order method of type
344
345 ; only collection element
346 (defconstant +OCI-ATTR-NUM-ELEMS+ 234)  ; number of elements
347
348 ; only type methods
349 (defconstant +OCI-ATTR-ENCAPSULATION+ 235) ; encapsulation level
350 (defconstant +OCI-ATTR-IS-SELFISH+ 236) ; method selfish
351 (defconstant +OCI-ATTR-IS-VIRTUAL+ 237) ; virtual
352 (defconstant +OCI-ATTR-IS-INLINE+ 238)  ; inline
353 (defconstant +OCI-ATTR-IS-CONSTANT+ 239) ; constant
354 (defconstant +OCI-ATTR-HAS-RESULT+ 240) ; has result
355 (defconstant +OCI-ATTR-IS-CONSTRUCTOR+ 241) ; constructor
356 (defconstant +OCI-ATTR-IS-DESTRUCTOR+ 242) ; destructor
357 (defconstant +OCI-ATTR-IS-OPERATOR+ 243) ; operator
358 (defconstant +OCI-ATTR-IS-MAP+ 244)     ; a map method
359 (defconstant +OCI-ATTR-IS-ORDER+ 245)   ; order method
360 (defconstant +OCI-ATTR-IS-RNDS+ 246)    ; read no data state method
361 (defconstant +OCI-ATTR-IS-RNPS+ 247)    ; read no process state
362 (defconstant +OCI-ATTR-IS-WNDS+ 248)    ; write no data state method
363 (defconstant +OCI-ATTR-IS-WNPS+ 249)    ; write no process state
364
365 ; describing public objects
366 (defconstant +OCI-ATTR-DESC-PUBLIC+ 250) ; public object
367 ;-
368
369 ;-OCIPasswordChange-
370 (defconstant +OCI-AUTH+ #x08)           ; Change the password but do not login
371
372
373 ;-Other Constants-
374 (defconstant +OCI-MAX-FNS+ 100)         ; max number of OCI Functions
375 (defconstant +OCI-SQLSTATE-SIZE+ 5)     ;
376 (defconstant +OCI-ERROR-MAXMSG-SIZE+ 1024) ; max size of an error message
377 ;; (defconstant +OCI-LOBMAXSIZE+ 4MAXVAL)       ; maximum lob data size
378 (defconstant +OCI-ROWID-LEN+ 23)        ;
379 ;-
380
381 ;- Fail Over Events -
382 (defconstant +OCI-FO-END+ #x00000001)   ;
383 (defconstant +OCI-FO-ABORT+ #x00000002) ; 
384 (defconstant +OCI-FO-REAUTH+ #x00000004) ;
385 (defconstant +OCI-FO-BEGIN+ #x00000008) ;
386 (defconstant +OCI-FO-ERROR+ #x00000010) ;
387 ;-
388
389 ;- Fail Over Types -
390 (defconstant +OCI-FO-NONE+ #x00000001)  ;
391 (defconstant +OCI-FO-SESSION+ #x00000002) ;
392 (defconstant +OCI-FO-SELECT+ #x00000004) ;
393 (defconstant +OCI-FO-TXNAL+ #x00000008) ;
394 ;-
395
396 ;-Function Codes-
397 (defconstant +OCI-FNCODE-INITIALIZE+ 1) ; OCIInitialize
398 (defconstant +OCI-FNCODE-HANDLEALLOC+ 2) ; OCIHandleAlloc
399 (defconstant +OCI-FNCODE-HANDLEFREE+ 3) ; OCIHandleFree
400 (defconstant +OCI-FNCODE-DESCRIPTORALLOC+ 4) ; OCIDescriptorAlloc
401 (defconstant +OCI-FNCODE-DESCRIPTORFREE+ 5) ; OCIDescriptorFree
402 (defconstant +OCI-FNCODE-ENVINIT+ 6)    ; OCIEnvInit
403 (defconstant +OCI-FNCODE-SERVERATTACH+ 7) ; OCIServerAttach
404 (defconstant +OCI-FNCODE-SERVERDETACH+ 8) ; OCIServerDetach
405 ; unused         9 
406 (defconstant +OCI-FNCODE-SESSIONBEGIN+ 10) ; OCISessionBegin
407 (defconstant +OCI-FNCODE-SESSIONEND+ 11) ; OCISessionEnd
408 (defconstant +OCI-FNCODE-PASSWORDCHANGE+ 12) ; OCIPasswordChange
409 (defconstant +OCI-FNCODE-STMTPREPARE+ 13) ; OCIStmtPrepare
410                                                       ; unused       14- 16
411 (defconstant +OCI-FNCODE-BINDDYNAMIC+ 17) ; OCIBindDynamic
412 (defconstant +OCI-FNCODE-BINDOBJECT+ 18) ; OCIBindObject
413                                                                 ; 19 unused
414 (defconstant +OCI-FNCODE-BINDARRAYOFSTRUCT+ 20) ; OCIBindArrayOfStruct
415 (defconstant +OCI-FNCODE-STMTEXECUTE+ 21) ; OCIStmtExecute
416                                                              ; unused 22-24
417 (defconstant +OCI-FNCODE-DEFINEOBJECT+ 25) ; OCIDefineObject
418 (defconstant +OCI-FNCODE-DEFINEDYNAMIC+ 26) ; OCIDefineDynamic
419 (defconstant +OCI-FNCODE-DEFINEARRAYOFSTRUCT+ 27) ; OCIDefineArrayOfStruct
420 (defconstant +OCI-FNCODE-STMTFETCH+ 28) ; OCIStmtFetch
421 (defconstant +OCI-FNCODE-STMTGETBIND+ 29) ; OCIStmtGetBindInfo
422                                                             ; 30, 31 unused
423 (defconstant +OCI-FNCODE-DESCRIBEANY+ 32) ; OCIDescribeAny
424 (defconstant +OCI-FNCODE-TRANSSTART+ 33) ; OCITransStart
425 (defconstant +OCI-FNCODE-TRANSDETACH+ 34) ; OCITransDetach
426 (defconstant +OCI-FNCODE-TRANSCOMMIT+ 35) ; OCITransCommit
427                                                                 ; 36 unused
428 (defconstant +OCI-FNCODE-ERRORGET+ 37)  ; OCIErrorGet
429 (defconstant +OCI-FNCODE-LOBOPENFILE+ 38) ; OCILobFileOpen
430 (defconstant +OCI-FNCODE-LOBCLOSEFILE+ 39) ; OCILobFileClose
431                                              ; 40 was LOBCREATEFILE, unused
432                                          ; 41 was OCILobFileDelete, unused
433 (defconstant +OCI-FNCODE-LOBCOPY+ 42)   ; OCILobCopy
434 (defconstant +OCI-FNCODE-LOBAPPEND+ 43) ; OCILobAppend
435 (defconstant +OCI-FNCODE-LOBERASE+ 44)  ; OCILobErase
436 (defconstant +OCI-FNCODE-LOBLENGTH+ 45) ; OCILobGetLength
437 (defconstant +OCI-FNCODE-LOBTRIM+ 46)   ; OCILobTrim
438 (defconstant +OCI-FNCODE-LOBREAD+ 47)   ; OCILobRead
439 (defconstant +OCI-FNCODE-LOBWRITE+ 48)  ; OCILobWrite
440                                                                 ; 49 unused
441 (defconstant +OCI-FNCODE-SVCCTXBREAK+ 50) ; OCIBreak
442 (defconstant +OCI-FNCODE-SERVERVERSION+ 51) ; OCIServerVersion
443 ; unused 52, 53
444 (defconstant +OCI-FNCODE-ATTRGET+ 54)   ; OCIAttrGet
445 (defconstant +OCI-FNCODE-ATTRSET+ 55)   ; OCIAttrSet
446 (defconstant +OCI-FNCODE-PARAMSET+ 56)  ; OCIParamSet
447 (defconstant +OCI-FNCODE-PARAMGET+ 57)  ; OCIParamGet
448 (defconstant +OCI-FNCODE-STMTGETPIECEINFO+ 58) ; OCIStmtGetPieceInfo
449 (defconstant +OCI-FNCODE-LDATOSVCCTX+ 59) ; OCILdaToSvcCtx
450                                                                 ; 60 unused
451 (defconstant +OCI-FNCODE-STMTSETPIECEINFO+ 61) ; OCIStmtSetPieceInfo
452 (defconstant +OCI-FNCODE-TRANSFORGET+ 62) ; OCITransForget
453 (defconstant +OCI-FNCODE-TRANSPREPARE+ 63) ; OCITransPrepare
454 (defconstant +OCI-FNCODE-TRANSROLLBACK+ 64) ; OCITransRollback
455 (defconstant +OCI-FNCODE-DEFINEBYPOS+ 65) ; OCIDefineByPos
456 (defconstant +OCI-FNCODE-BINDBYPOS+ 66) ; OCIBindByPos
457 (defconstant +OCI-FNCODE-BINDBYNAME+ 67) ; OCIBindByName
458 (defconstant +OCI-FNCODE-LOBASSIGN+ 68) ; OCILobAssign
459 (defconstant +OCI-FNCODE-LOBISEQUAL+ 69) ; OCILobIsEqual
460 (defconstant +OCI-FNCODE-LOBISINIT+ 70) ; OCILobLocatorIsInit
461 ; 71 was lob locator size in beta2
462 (defconstant +OCI-FNCODE-LOBENABLEBUFFERING+ 71) ; OCILobEnableBuffering
463 (defconstant +OCI-FNCODE-LOBCHARSETID+ 72) ; OCILobCharSetID
464 (defconstant +OCI-FNCODE-LOBCHARSETFORM+ 73) ; OCILobCharSetForm
465 (defconstant +OCI-FNCODE-LOBFILESETNAME+ 74) ; OCILobFileSetName
466 (defconstant +OCI-FNCODE-LOBFILEGETNAME+ 75) ; OCILobFileGetName
467 (defconstant +OCI-FNCODE-LOGON+ 76)     ; OCILogon
468 (defconstant +OCI-FNCODE-LOGOFF+ 77)    ; OCILogoff
469 (defconstant +OCI-FNCODE-LOBDISABLEBUFFERING+ 78) ; OCILobDisableBuffering
470 (defconstant +OCI-FNCODE-LOBFLUSHBUFFER+ 79) ; OCILobFlushBuffer
471 (defconstant +OCI-FNCODE-LOBLOADFROMFILE+ 80) ; OCILobLoadFromFile
472
473
474 ;-
475
476 ;- FILE open modes -
477 (defconstant +OCI-FILE-READONLY+ 1)     ; readonly mode open for FILE types
478 ;-
479
480 ;- LOB Buffering Flush Flags -
481 (defconstant +OCI-LOB-BUFFER-FREE+ 1)   ;
482 (defconstant +OCI-LOB-BUFFER-NOFREE+ 2) ;
483 ;-
484
485 ;- OCI Statement Types -
486
487 (defconstant +oci-stmt-select+ 1)       ; select statement
488 (defconstant +oci-stmt-update+ 2)       ; update statement
489 (defconstant +oci-stmt-delete+ 3)       ; delete statement
490 (defconstant +oci-stmt-insert+ 4)       ; insert statement
491 (defconstant +oci-stmt-create+ 5)       ; create statement
492 (defconstant +oci-stmt-drop+ 6)         ; drop statement
493 (defconstant +oci-stmt-alter+ 7)        ; alter statement
494 (defconstant +oci-stmt-begin+ 8)        ; begin ... (pl/sql statement)
495 (defconstant +oci-stmt-declare+ 9)      ; declare .. (pl/sql statement )
496 ;-
497
498 ;- OCI Parameter Types -
499 (defconstant +OCI-PTYPE-UNK+ 0)         ; unknown
500 (defconstant +OCI-PTYPE-TABLE+ 1)       ; table
501 (defconstant +OCI-PTYPE-VIEW+ 2)        ; view
502 (defconstant +OCI-PTYPE-PROC+ 3)        ; procedure
503 (defconstant +OCI-PTYPE-FUNC+ 4)        ; function
504 (defconstant +OCI-PTYPE-PKG+ 5)         ; package
505 (defconstant +OCI-PTYPE-TYPE+ 6)        ; user-defined type
506 (defconstant +OCI-PTYPE-SYN+ 7)         ; synonym
507 (defconstant +OCI-PTYPE-SEQ+ 8)         ; sequence
508 (defconstant +OCI-PTYPE-COL+ 9)         ; column
509 (defconstant +OCI-PTYPE-ARG+ 10)        ; argument
510 (defconstant +OCI-PTYPE-LIST+ 11)       ; list
511 (defconstant +OCI-PTYPE-TYPE-ATTR+ 12)  ; user-defined type's attribute
512 (defconstant +OCI-PTYPE-TYPE-COLL+ 13)  ; collection type's element
513 (defconstant +OCI-PTYPE-TYPE-METHOD+ 14) ; user-defined type's method
514 (defconstant +OCI-PTYPE-TYPE-ARG+ 15)   ; user-defined type method's argument
515 (defconstant +OCI-PTYPE-TYPE-RESULT+ 16) ; user-defined type method's result
516 ;-
517
518 ;- OCI List Types -
519 (defconstant +OCI-LTYPE-UNK+ 0)         ; unknown
520 (defconstant +OCI-LTYPE-COLUMN+ 1)      ; column list
521 (defconstant +OCI-LTYPE-ARG-PROC+ 2)    ; procedure argument list
522 (defconstant +OCI-LTYPE-ARG-FUNC+ 3)    ; function argument list
523 (defconstant +OCI-LTYPE-SUBPRG+ 4)      ; subprogram list
524 (defconstant +OCI-LTYPE-TYPE-ATTR+ 5)   ; type attribute
525 (defconstant +OCI-LTYPE-TYPE-METHOD+ 6) ; type method
526 (defconstant +OCI-LTYPE-TYPE-ARG-PROC+ 7) ; type method w/o result argument list
527 (defconstant +OCI-LTYPE-TYPE-ARG-FUNC+ 8) ; type method w/result argument list
528
529 ;; typecodes
530