OTL 4.0, Examples for Oracle 8,8i
The examples below work with Oracle 8, 8i /
OCI8, 8i. In general, all of these examples should work with any Oracle
version higher than Oracle 8.0, when OCI8, or OCI8i are enabled in OTL
by setting
#define OTL_ORA8, OTL_ORA8I. Oracle normally
provides decent backward compatibility, at least at the source code
level. All examples for Oracle 7
should work when OTL_ORA8,
or OTL_ORA8I is enabled.
- Example 10 (Simple Insert/Select)
- Example 11 ("Incompatible
datatypes
in stream operation" exception)
- Example 12 (PL/SQL block)
- Example 13 (Insert and Select via
referenced cursor)
- Example 14 (Simple Insert/Select
with the LONG datatype)
- Example 15 (Simple Insert/Select
with the LONG RAW datatype)
- Example 16
(otl_stream::describe_select() with a simple Select)
- Example 17
(otl_stream::describe_select() with a referenced cursor)
- Example 18 (otl_stream and NULLs)
- Example 19 (Simple Insert/Select
with the CLOB datatype)
- Example 20 (Simple Insert/Select
with the BLOB datatype)
- Example
62 (Insert and Select via
referenced cursor for Oracle 8i)
- Example
63
(otl_stream::describe_select() with a simple Select for Oracle 8i)
- Example
64
(otl_stream::describe_select() with a referenced cursor for Oracle 8i)
- Example
36 (otl_nocommit_stream in
Oracle 8)
- Examle
39 (otl_datetime in Oracle
8)
- Example
41
(Insert/Update/Select with CLOB in Oracle 8)
- Example
42 (ODBC, OCI: LONG ==>
CLOB. How to use OTL namespaces)
- Example
44 (Get Rows Processed
Count in Oracle 8)
- Example
47 ("Auto-commit every SQL
statement / commit-on-sucess" mode in Oracle 8)
- Example
50 (PL/SQL tables as
parameters, Oracle 8)
- Example
52 (PL/SQL table of DATEs
as parameter, Oracle 8)
- Example
54 (Datatype override in
SELECT, Oracle 8)
- Example
56
(Insert/Update/Select with Oracle 8 CLOB in stream mode)
- Example
57 (Insert/Update/Select
with Oracle 8 BLOB in stream mode)
- Example
59 (Using OTL/OCI8 in
Pro*C/C++ environment)
- Example
60 (Using OTL/OCI8:
server_attach/detach and session_begin/end)
- Example
61 (Using OTL/OCI8:
server_attach/detach, session_begin/end, and session_reopen)
- Example
66 (Simple Insert/Select
and otl_stream::clean() function for Oracle 8/8i)
- Example
69 (Dynamically allocated
PL/SQL tables as parameters, Oracle 8)
- Example
71 (Dynamically allocated
PL/SQL table of DATEs as parameter, Oracle 8)
- Example
73 (STL std::strings, ANSI
C++ typecasts, Oracle 8)
- Example
76 (STL-compliant OTL
stream iterators, Oracle 8)
- Example
86 (STL vector based
PL/SQL
tables as parameters, Oracle 8)
- Example
88 (STL vector based
PL/SQL
table of DATEs as parameter, Oracle 8)
- Example
98 (otl_value<T>,
Oracle 8/8i)
- Example
102 (#define
OTL_UNCAUGHT_EXCEPTION_ON, Oracle 8/8i)
- Example
111 (Group data type
override in SELECT, Oracle 8/8i)
- Example
113 (OTL stream
pooling, Oracle 8/8i)
- Example
116
(otl_stream::set_flush(), Oracle 8/8i)
- Example
119 (OTL_VALUE_TEMPLATE_ON,
OTL_USER_DEFINED_STRING_CLASS_ON, Oracle 8/8i)
- Example
122
(Insert/Update/Select with Oracle 8i CLOB in stream mode)
- Example
123 (Insert/Update/Select
with Oracle 8i BLOB in stream mode)
- Example
130 (Describe
otl_stream's bind variables for Oracle 8i)
- Example
148 (otl_refcur_stream, basic)
- Example
149 (otl_refcur_stream,
stored procedure)
- Example
150 (otl_refcur_stream,
PL/SQL tables and reference cursors as parameters in stored procedure)
- Example
151 (otl_refcur_stream
and
otl_lob_stream, used together)
- Example
152 (get_stream_type)
- Example
153 (create_stored_proc_call)
- Example
156 (OTL/OCI8/9, otl_connect::cancel())
- Example
159 (otl_stream::clean(), cancelling SELECT's fetch sequence, Oracle
8i/9i )
- Example
162 (otl_stream::clean(),
cancelling REF CURSOR's fetch sequence, Oracle 8i/9i)
- Example
164
(otl_stream::clean(), cleaning the SELECT stream's error flags, Oracle
8i/9i )
- Example
167 (otl_stream::clean(),
cleaning the REF CURSOR otl_stream's error flags, Oracle 8i/9i )
- Example
169 (#define's OTL_DEFAULT_XXX_NULL_TO_VAL, Oracle 7/8/8i/9i)
- Example
172 (#define OTL_ORA_TEXT_ON, Oracle 8/8i/9i)
- Example
173 (#define
OTL_ORA_TEXT_ON, Oracle 8/8i/9i)
- Example
204 (otl_datetime
container with TIMESTAMP values down to microseconds in Oracle 9i)
- Example
205 (otl_exception, derived from a base
class, Oracle)
- Example
208 (lob_stream and SELECT INTO FOR UPDATE, Oracle)
- Example
210 (Oracle and RAW column)
- Example
211 (OTL_ADD_NULL_TERMINATOR_STRING_SIZE,Oracle)
- Example
219 (otl_connect::change_password() and Oracle 8i/9i)
- Example
221 (std::string and
LONGs, Oracle 8/8i/9i)
- Example
222 (std::string and
CLOBs, Oracle 8/8i/9i)
- Example
232 (otl_stream::flush() and duplicate rows, Oracle 8, 8i, 9i)
- Example
233 (#define OTL_ORA_MAP_STRINGS_TO_CHARZ, Oracle 8, 8i, 9i)
- Example
234 (SQL statement label, Oracle 8,8i,9i)
- Example
245 (user defined string class and LONGs, Oracle 8/8i/9i)
- Example
246 (user defined string class and CLOBs, Oracle 8/8i/9i)
- Example
250 (OTL tracing, Oracle 8/8i/9i)
- Example
254 (Explict bind variables in SELECT statement column definitions,
Oracle 8/8i/9i)
- Example
258 (64-bit signed integers,
Oracle 8/8i/9i)
- Example
260 (OTL stream read iterator, simple SELECT,
Oracle)
- Example
261 (OTL stream read iterator, reference cursor,
Oracle)
- Example
289 (Strict numeric type checking on SELECTs)
- Example 292 (common interface for
otl_stream and otl_refcur_stream)
- Example 308 (Stream buffer size as int, simple Insert/Select)
- Example 312 (Large PL/SQL tables as
parameters)
- Example 314 (PL/SQL tables of CHAR
and VARCHAR2 together as
parameters)
- Example 315
(Insert/Update/Select with Oracle 8i CLOB in stream mode and
otl_stream_read_iterator)
- Example 316
(Insert/Update/Select with Oracle 8i BLOB in stream mode and
otl_stream_read_iterator)
- Example 339 (OTL stream read
iterator, "get by name" functions,
Oracle)
- Example 372 (Simple Insert/Select,
otl_connect::operator<<, <<=, >>)
- Example 378
(Insert/Update/Select with Oracle 8i/9i/10g CLOB in stream mode and
stored procs)
- Example 379
(Insert/Update/Select, Oracle 8i/9i/10g CLOBs in stream mode, and
std:strings)
- Example 385
(Insert/Update/Select with Oracle 8i/9i/10g CLOB in stream mode and
otl_long_string::set_last_piece())
- Example 386 (Insert/Update/Select
with Oracle 8i/9i/10g BLOB in stream mode and
otl_long_string::set_last_piece())
- Example 446 (Simple Insert/Select
with Oracle RAW datatype)
- Example 457 (Simple Insert/Select
with Oracle RAW datatype and otl_stream_read_iterator)
- Example 687 (OTL stream read
iterator,
otl_refcur_stream, Oracle)
- Example 692
(Customizing the date
format in OTL tracing via #define OTL_TRACE_FORMAT_DATETIME)
- Example 693 (Skipping to the end of
the row with otl_stream::skip_to_end_of_row())
Prev NextContentsGo Home
Copyright © 1996-2009, Sergei Kuchin, email: skuchin@aceweb.com, skuchin@gmail.com
.
Permission to use, copy, modify and redistribute this document
for any purpose is hereby granted without fee, provided that the above
copyright notice appear in all copies. THE SOFTWARE IS PROVIDED "AS IS"
AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE
INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO
EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR
CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF
USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.