Programmer's Guide to the Oracle Precompilers
Release 7.3
Part Number A42525-01
Home
Book List
Contents
Index
Master Index
Feedback
Programmer's Guide to the Oracle
®
Precompilers
Preface
What This Guide Has to Offer
Who Should Read This Guide?
What's New in Release 1.8?
How This Guide Is Organized
Conventions Used in This Guide
Standards Compliance
Your Comments Are Welcome
Getting Acquainted
What Is an Oracle Precompiler?
Why Use an Oracle Precompiler?
Why Use SQL?
Why Use PL/SQL?
What Do the Oracle Precompilers Offer?
Do the Oracle Precompilers Meet Industry Standards?
Learning the Basics
Key Concepts of Embedded SQL Programming
Steps in Developing an Embedded SQL Application
A Program Example
Sample Tables
Meeting Program Requirements
The Declare Section
INCLUDE Statements
The SQLCA
Oracle Datatypes
Datatype Conversion
Declaring and Referencing Host Variables
Declaring and Referencing Indicator Variables
Datatype Equivalencing
National Language Support
Multi-Byte NLS Character Sets
Connecting to Oracle
Concurrent Logons
Embedding OCI (Oracle Call Interface) Calls
Developing X/Open Applications
Using Embedded SQL
Using Host Variables
Using Indicator Variables
The Basic SQL Statements
Cursors
Cursor Variables
Using Embedded PL/SQL
Advantages of PL/SQL
Embedding PL/SQL Blocks
Using Host Variables
Using Indicator Variables
Using Host Arrays
Using Cursors
Stored Subprograms
Using Dynamic PL/SQL
Running the Oracle Precompilers
The Precompiler Command
What Occurs during Precompilation?
Precompiler Options
Entering Options
Scope of Options
Quick Reference
Using the Precompiler Options
Conditional Precompilations
Separate Precompilations
Compiling and Linking
Defining and Controlling Transactions
Some Terms You Should Know
How Transactions Guard Your Database
How to Begin and End Transactions
Using the COMMIT Statement
Using the ROLLBACK Statement
Using the SAVEPOINT Statement
Using the RELEASE Option
Using the SET TRANSACTION Statement
Overriding Default Locking
Fetching Across Commits
Handling Distributed Transactions
Guidelines
Error Handling and Diagnostics
The Need for Error Handling
Error Handling Alternatives
Using Status Variables when MODE={ANSI|ANSI14}
Using the SQL Communications Area
Using the Oracle Communications Area
Using Host Arrays
What Is a Host Array?
Why Use Arrays?
Declaring Host Arrays
Using Arrays in SQL Statements
Selecting into Arrays
Inserting with Arrays
Updating with Arrays
Deleting with Arrays
Using Indicator Arrays
Using the FOR Clause
Using the WHERE Clause
Mimicking the CURRENT OF Clause
Using SQLERRD(3)
Using Dynamic SQL
What Is Dynamic SQL?
Advantages and Disadvantages of Dynamic SQL
When to Use Dynamic SQL
Requirements for Dynamic SQL Statements
How Dynamic SQL Statements Are Processed
Methods for Using Dynamic SQL
Using Method 1
Using Method 2
Using Method 3
Using Method 4
Using the DECLARE STATEMENT Statement
Using Host Arrays
Using PL/SQL
Writing User Exits
What Is a User Exit?
Why Write a User Exit?
Developing a User Exit
Writing a User Exit
Calling a User Exit
Passing Parameters to a User Exit
Returning Values to a Form
An Example
Precompiling and Compiling a User Exit
Using the GENXTB Utility
Linking a User Exit into SQL*Forms
Guidelines for SQL*Forms User Exits
EXEC TOOLS Statements
New Features
Fetching NULLs without Using Indicator Variables
Oracle Reserved Words, Keywords, and Namespaces
Oracle Reserved Words
Oracle Keywords
PL/SQL Reserved Words
Oracle Reserved Namespaces
Performance Tuning
What Causes Poor Performance?
How Can Performance be Improved?
Using Host Arrays
Using Embedded PL/SQL
Optimizing SQL Statements
Using Indexes
Taking Advantage of Row-Level Locking
Eliminating Unnecessary Parsing
Syntactic and Semantic Checking
What Is Syntactic and Semantic Checking?
Controlling the Type and Extent of Checking
Specifying SQLCHECK=SEMANTICS
Migrating to Oracle7
Embedded SQL Commands and Directives
Summary of Precompiler Directives and Embedded SQL Commands
About The Command Descriptions
How to Read Syntax Diagrams
ALLOCATE (Executable Embedded SQL Extension)
CLOSE (Executable Embedded SQL)
COMMIT (Executable Embedded SQL)
CONNECT (Executable Embedded SQL Extension)
DECLARE CURSOR (Embedded SQL Directive)
DECLARE DATABASE (Oracle Embedded SQL Directive)
DECLARE STATEMENT (Embedded SQL Directive)
DECLARE TABLE (Oracle Embedded SQL Directive)
DELETE (Executable Embedded SQL)
DESCRIBE (Executable Embedded SQL)
EXECUTE ... END-EXEC (Executable Embedded SQL Extension)
EXECUTE (Executable Embedded SQL)
EXECUTE IMMEDIATE (Executable Embedded SQL)
FETCH (Executable Embedded SQL)
INSERT (Executable Embedded SQL)
OPEN (Executable Embedded SQL)
PREPARE (Executable Embedded SQL)
ROLLBACK (Executable Embedded SQL)
SAVEPOINT (Executable Embedded SQL)
SELECT (Executable Embedded SQL)
UPDATE (Executable Embedded SQL)
VAR (Oracle Embedded SQL Directive)
WHENEVER (Embedded SQL Directive)
Copyright © 1996, 2001 Oracle Corporation.
All Rights Reserved.
Home
Book List
Contents
Index
Master Index
Feedback