Skip Headers
Oracle® SQL*Module for Ada Programmer's Guide
10
g
Release 2 (10.2)
Part Number A58231-03
Home
Book List
Index
Master Index
Feedback
Next
View PDF
Contents
List of Figures
List of Tables
Title and Copyright Information
Preface
Intended Audience
Documentation Accessibility
Standards Conformance
Conventions
1
Introduction to SQL*Module
What Is SQL*Module?
Background
Precompilers
The Module Language Concept
SQL*Module as an Interface Builder
What Is Supported by SQL*Module?
What SQL Statements are Not Supported by SQL*Module?
2
Module Language
The Module
An Example Module
A Short Example Program in Ada
Structure of a Module
Preamble
MODULE Clause
LANGUAGE Clause
AUTHORIZATION Clause
Cursor Declarations
Procedure Definitions
Procedure Name
Parameter List
SQL92 Syntax
SQL Datatypes
SQL Commands
Text in a Module
Comments
Indicator Parameters
Status Parameters
Error Messages
CONNECT Statement
SET CONNECTION Statement
DISCONNECT Statement
Multi-tasking
ENABLE THREADS
SQL_CONTEXT Datatype
CONTEXT ALLOCATE
CONTEXT FREE
Multi-tasking Restrictions
Multi-tasking Example
3
Accessing Stored Procedures
PL/SQL
Procedures
Stored Procedures
Stored Packages
Accessing Stored Procedures
Case of Package and Procedure Names
Early and Late Binding
Cursor Variables
Cursor Variable Parameters
Allocating a Cursor Variable
Opening a Cursor Variable
Opening in a Stand-alone Stored Procedure
Return Types
Closing a Cursor Variable
Restrictions on Cursor Variables
Dynamic SQL
The WITH INTERFACE Clause
Examples
SQL Datatypes
DATE Datatype
The Default WITH INTERFACE Clause
Procedures
Functions
Storing Module Language Procedures
Connecting to a Database
4
Developing the Ada Application
Program Structure
Error Handling
SQLCODE
Obtaining Error Message Text
SQLSTATE
Obtaining the Number of Rows Processed
Handling Nulls
Indicator Variables
Cursors
Specification Files
Calling a Procedure
Arrays as Procedure Arguments
Globalization Support
5
Running SQL*Module
SQL*Module Input and Output
Input sources
Output Files
Determining the Input Source
Invoking SQL*Module
Running the Compiler
Case Sensitivity in Program Names, Option Names, and Values
Listing Options and Default Values
How to Specify Command-Line Options
Value Lists
Default Values
Configuration Files
Input Files
Output Files
Source Code Output File
Default File Names for Ada
Specification File
Default Specification Filenames for Ada
Listing File
PL/SQL Source Files
Avoid Default Output Filenames
Command-Line Options
AUTO_CONNECT
BINDING
CONFIG
ERRORS
FIPS
INAME
LNAME
LTYPE
MAPPING
MAXLITERAL
ONAME
OUTPUT
PNAME
RPC_GENERATE
SELECT_ERROR
SNAME
STORE_PACKAGE
SQLCHECK
USERID
Compiling and Linking
An Example (Module Language)
6
Demonstration Programs
The SQL_STANDARD Package
SQLCODE
SQLSTATE
Sample Programs
Sample Tables
MKTABLES.SQL
DEPARTMT.SQL
INSTRUCS.SQL
STUDENTS.SQL
COURSES.SQL
EMROLMNT.SQL
Module Language Sample Program
Calling a Stored Procedure
Sample Applications
DEMOHOST.A
DEMCALSP.A
A
New Features
New Statements
Other New Features
B
Module Language Syntax
Module Language Syntax Diagrams
Preamble
LANGUAGE Clause
AUTHORIZATION Clause
Cursors
Procedure Definitions
WITH INTERFACE CLAUSE
C
Reserved Words
Module Reserved Words
D
SQLSTATE Codes
SQLSTATE Codes
E
System-Specific References
System-Specific Aspects of SQL*Module
Supported Compilers
Character Case in Command Lines
Location of Files
Filename Extensions
Ada Output Files
Command Line
Ada SQL_STANDARD Package
Index