Skip Headers

Oracle9i Application Developer's Guide - Fundamentals
Release 2 (9.2)

Part Number A96590-01
Go To Documentation Library
Home
Go To Product List
Book List
Go To Table Of Contents
Contents
Go To Index
Index

Master Index

Feedback

Go to previous page Go to next page


Preface

The Oracle9i Application Developer's Guide - Fundamentals describes features of application development for the Oracle9i Database. Information in this guide applies to features that work the same on all platforms, and does not include system-specific information.

This preface contains these topics:

Audience

The Oracle9i Application Developer's Guide - Fundamentals is intended for programmers developing new applications or converting existing applications to run in the Oracle environment. This book will also be valuable to systems analysts, project managers, and others interested in the development of database applications.

This guide assumes that you have a working knowledge of application programming, and that you are familiar with the use of Structured Query Language (SQL) to access information in relational database systems.

Certain sections of this guide also assume a knowledge of the basic concepts of object-oriented programming.

Duties of an Application Developer

Activities that are typically required of an application developer include:

Organization

This document contains:

Part I: Introduction

This part introduces several different ways that you can write Oracle applications. You might need to use more than one language or development environment for a single application. Some database features are only supported, or are easier to access from, certain languages.

Chapter 1, "Understanding the Oracle Programmatic Environments" outlines the strengths of the languages, development environments, and APIs that Oracle provides.

Part II: Designing the Database

Before you develop an application, you need to plan the characteristics of the associated database. You must choose all the pieces that go into the database, and how they are put together. Good database design helps ensure good performance and scalability, and reduces the amount of application logic you code by making the database responsible for things like error checking and fast data access.

Chapter 2, "Managing Schema Objects" explains how to manage objects such as tables, views, numeric sequences, and synonyms. It also discusses performance enhancements to data retrieval through the use of indexes and clusters.

Chapter 3, "Selecting a Datatype" explains how to represent your business data in the database. The datatypes include fixed- and variable-length character strings, numeric data, dates, raw binary data, and row identifiers (ROWIDs).

Chapter 4, "Maintaining Data Integrity Through Constraints" explains how to use constraints to move error-checking logic out of your application and into the database.

Chapter 5, "Selecting an Index Strategy" and Chapter 6, "Speeding Up Index Access with Index-Organized Tables" explain how to speed up queries.

Chapter 7, "How Oracle Processes SQL Statements" explains SQL topics such as commits, cursors, and locking that you can take advantage of in your applications.

Chapter 8, "Coding Dynamic SQL Statements" describes dynamic SQL, compares native dynamic SQL to the DBMS_SQL package, and explains when to use dynamic SQL.

Chapter 9, "Using Procedures and Packages" explains how to store reusable procedures in the database, and how to group procedures into packages. Chapter 10, "Calling External Procedures" explains how to code the bodies of computationally intensive procedures in languages other than PL/SQL.

Part III: Application Security

Chapter 11, "Database Security Overview for Application Developers" provides background information that you will need before addressing security issues in your applications.

Chapter 12, "Implementing Application Security Policies" explains the major security mechanisms you can use in applications: application context, fine-grained access control, and virtual private database.

Chapter 13, "Proxy Authentication" explains how to tie together authentication done by the web server or application server, with the security mechanisms of the database server.

Chapter 14, "Data Encryption Using DBMS_OBFUSCATION_TOOLKIT" explains how to secure data so that even if an unauthorized person can see the data, they cannot decode it.

Part IV: The Active Database

You can include all sorts of programming logic in the database itself, making the benefits available to many applications and saving repetitious coding work.

Chapter 15, "Using Triggers" explains how to make the database do special processing before, after, or instead of running SQL statements. You can use triggers for things like validating or transforming data, or logging database access. Chapter 16, "Working With System Events" explains how to retrieve information, such as the user ID and database name, about the event that fires a trigger.

Chapter 17, "Using the Publish-Subscribe Model for Applications" introduces the Oracle model for asynchronous communication, also known as messaging or queuing.

Part IV: Developing Specialized Applications

Chapter 18, "Developing Web Applications with PL/SQL" explains how to create dynamic web pages and applications that work with the Internet, e-mail, and so on, using the PL/SQL language.

Chapter 19, "Porting Non-Oracle Applications to Oracle9i" lists some features and techniques you can use to make applications originally written for another database system run on Oracle9i.

Chapter 20, "Working with Transaction Monitors with Oracle XA" describes how to connect Oracle with a transaction monitor.

Related Documentation

For more information, see these Oracle resources:

Use the PL/SQL User's Guide and Reference to learn PL/SQL and to get a complete description of this high-level programming language, which is Oracle Corporation's procedural extension to SQL.

The Oracle Call Interface (OCI) is described in Oracle Call Interface Programmer's Guide and Oracle C++ Call Interface Programmer's Guide .

You can use the OCI to build third-generation language (3GL) applications that access the Oracle Server.

Oracle Corporation also provides the Pro* series of precompilers, which allow you to embed SQL and PL/SQL in your application programs. If you write 3GL application programs in C, C++, COBOL, or FORTRAN that incorporate embedded SQL, then refer to the corresponding precompiler manual. For example, if you program in C or C++, then refer to the Pro*C/C++ Precompiler Programmer's Guide.

Oracle Developer/2000 is a cooperative development environment that provides several tools including a form builder, reporting tools, and a debugging environment for PL/SQL. If you use Developer/2000, then refer to the appropriate Oracle Tools documentation.

For SQL information, see the Oracle9i SQL Reference and Oracle9i Database Administrator's Guide. For basic Oracle concepts, see Oracle9i Database Concepts.

For developing applications that manipulate XML data, see Oracle9i XML Developer's Kits Guide - XDK and Oracle9i XML API Reference - XDK and Oracle XML DB.

Many of the examples in this book use the sample schemas of the seed database, which is installed by default when you install Oracle. Refer to Oracle9i Sample Schemas for information on how these schemas were created and how you can use them yourself.

In North America, printed documentation is available for sale in the Oracle Store at

http://oraclestore.oracle.com/

Customers in Europe, the Middle East, and Africa (EMEA) can purchase documentation from

http://www.oraclebookshop.com/

Other customers can contact their Oracle representative to purchase printed documentation.

To download free release notes, installation documentation, white papers, or other collateral, please visit the Oracle Technology Network (OTN). You must register online before using OTN; registration is free and can be done at

http://otn.oracle.com/admin/account/membership.html

If you already have a username and password for OTN, then you can go directly to the documentation section of the OTN Web site at

http://otn.oracle.com/docs/index.htm

To access the database documentation search engine directly, please visit

http://tahiti.oracle.com/

This search engine has a number of features that you might find useful, such as searching for examples, looking up SQL and PL/SQL syntax, and formatting large numbers of search results into a "virtual book".

Conventions

This section describes the conventions used in the text and code examples of this documentation set. It describes:

Conventions in Text

We use various conventions in text to help you more quickly identify special terms. The following table describes those conventions and provides examples of their use.

Convention Meaning Example

Bold

Bold typeface indicates terms that are defined in the text or terms that appear in a glossary, or both.

When you specify this clause, you create an index-organized table.

Italics

Italic typeface indicates book titles or emphasis.

Oracle9i Database Concepts

Ensure that the recovery catalog and target database do not reside on the same disk.

UPPERCASE monospace (fixed-width font)

Uppercase monospace typeface indicates elements supplied by the system. Such elements include parameters, privileges, datatypes, RMAN keywords, SQL keywords, SQL*Plus or utility commands, packages and methods, as well as system-supplied column names, database objects and structures, usernames, and roles.

You can specify this clause only for a NUMBER column.

You can back up the database by using the BACKUP command.

Query the TABLE_NAME column in the USER_TABLES data dictionary view.

Use the DBMS_STATS.GENERATE_STATS procedure.

lowercase monospace (fixed-width font)

Lowercase monospace typeface indicates executables, filenames, directory names, and sample user-supplied elements. Such elements include computer and database names, net service names, and connect identifiers, as well as user-supplied database objects and structures, column names, packages and classes, usernames and roles, program units, and parameter values.

Note: Some programmatic elements use a mixture of UPPERCASE and lowercase. Enter these elements as shown.

Enter sqlplus to open SQL*Plus.

The password is specified in the orapwd file.

Back up the datafiles and control files in the /disk1/oracle/dbs directory.

The department_id, department_name, and location_id columns are in the hr.departments table.

Set the QUERY_REWRITE_ENABLED initialization parameter to true.

Connect as oe user.

The JRepUtil class implements these methods.

lowercase monospace (fixed-width font) italic

Lowercase monospace italic font represents placeholders or variables.

You can specify the parallel_clause.

Run Uold_release.SQL where old_release refers to the release you installed prior to upgrading.

Conventions in Code Examples

Code examples illustrate SQL, PL/SQL, SQL*Plus, or other command-line statements. They are displayed in a monospace (fixed-width) font and separated from normal text as shown in this example:

SELECT username FROM dba_users WHERE username = 'MIGRATE';

The following table describes typographic conventions used in code examples and provides examples of their use.

Convention Meaning Example

[ ]

Brackets enclose one or more optional items. Do not enter the brackets.

DECIMAL (digits [ , precision ])

{ }

Braces enclose two or more items, one of which is required. Do not enter the braces.

{ENABLE | DISABLE}

|

A vertical bar represents a choice of two or more options within brackets or braces. Enter one of the options. Do not enter the vertical bar.

{ENABLE | DISABLE}

[COMPRESS | NOCOMPRESS]

...

Horizontal ellipsis points indicate either:

  • That we have omitted parts of the code that are not directly related to the example
  • That you can repeat a portion of the code

CREATE TABLE ... AS subquery;

SELECT col1, col2, ... , coln FROM employees;

.

.

.

Vertical ellipsis points indicate that we have omitted several lines of code not directly related to the example.

Other notation

You must enter symbols other than brackets, braces, vertical bars, and ellipsis points as shown.

acctbal NUMBER(11,2);

acct CONSTANT NUMBER(4) := 3;

Italics

Italicized text indicates placeholders or variables for which you must supply particular values.

CONNECT SYSTEM/system_password

DB_NAME = database_name

UPPERCASE

Uppercase typeface indicates elements supplied by the system. We show these terms in uppercase in order to distinguish them from terms you define. Unless terms appear in brackets, enter them in the order and with the spelling shown. However, because these terms are not case sensitive, you can enter them in lowercase.

SELECT last_name, employee_id FROM employees;

SELECT * FROM USER_TABLES;

DROP TABLE hr.employees;

lowercase

Lowercase typeface indicates programmatic elements that you supply. For example, lowercase indicates names of tables, columns, or files.

Note: Some programmatic elements use a mixture of UPPERCASE and lowercase. Enter these elements as shown.

SELECT last_name, employee_id FROM employees;

sqlplus hr/hr

CREATE USER mjones IDENTIFIED BY ty3MU9;

Documentation Accessibility

Our goal is to make Oracle products, services, and supporting documentation accessible, with good usability, to the disabled community. To that end, our documentation includes features that make information available to users of assistive technology. This documentation is available in HTML format, and contains markup to facilitate access by the disabled community. Standards will continue to evolve over time, and Oracle Corporation is actively engaged with other market-leading technology vendors to address technical obstacles so that our documentation can be accessible to all of our customers. For additional information, visit the Oracle Accessibility Program Web site at

http://www.oracle.com/accessibility/

Accessibility of Code Examples in Documentation

JAWS, a Windows screen reader, may not always correctly read the code examples in this document. The conventions for writing code require that closing braces should appear on an otherwise empty line; however, JAWS may not always read a line of text that consists solely of a bracket or brace.

Accessibility of Links to External Web Sites in Documentation

This documentation may contain links to Web sites of other companies or organizations that Oracle Corporation does not own or control. Oracle Corporation neither evaluates nor makes any representations regarding the accessibility of these Web sites.


Go to previous page Go to next page
Oracle
Copyright © 1996, 2002 Oracle Corporation.

All Rights Reserved.
Go To Documentation Library
Home
Go To Product List
Book List
Go To Table Of Contents
Contents
Go To Index
Index

Master Index

Feedback