Oracle® Database Utilities 10g Release 1 (10.1) Part Number B10825-01 |
|
|
View PDF |
This document describes how to use the Oracle Database utilities for data transfer, data maintenance, and database administration. The preface contains these topics:
Oracle Database Utilities is intended for database administrators (DBAs), application programmers, security administrators, system operators, and other Oracle users who perform the following tasks:
Archive data, back up an Oracle database, or move data between Oracle databases using the Export and Import utilities (both the original versions and the Data Pump versions)
Load data into Oracle tables from operating system files using SQL*Loader or from external sources using the external tables feature
Perform a physical data structure integrity check on an offline database, using the DBVERIFY utility
Maintain the internal database identifier (DBID) and the database name (DBNAME) for an operational database, using the DBNEWID utility
Extract and manipulate complete representations of the metadata for database objects, using the Metadata API
Query and analyze redo log files (through a SQL interface) using the LogMiner utility
To use this manual, you need a working knowledge of SQL and Oracle fundamentals, information that is contained in Oracle Database Concepts. In addition, SQL*Loader requires that you know how to use the file management facilities of your operating system.
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 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/
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.
This document contains:
This chapter provides an overview of Oracle Data Pump technology, which enables very high-speed movement of data and metadata from one database to another.
This chapter describes the Oracle Data Pump Export utility, which is used to unload data and metadata into a set of operating system files called a dump file set.
This chapter describes the Oracle Data Pump Import utility, which is used to load an export dump file set into a target system. It also describes how to perform a network import to load a target database directly from a source database with no intervening files.
This chapter discusses why the performance of Data Pump Export and Import is better than that of original Export and Import. It also suggests specific steps you can take to enhance performance of export and import operations.
This chapter describes how the Data Pump API, DBMS_DATAPUMP
, works.
This chapter introduces SQL*Loader and describes its features. It also introduces data loading concepts (including object support). It discusses input to SQL*Loader, database preparation, and output from SQL*Loader.
This chapter describes the command-line syntax used by SQL*Loader. It discusses invoking SQL*Loader, command-line arguments, and exit codes.
This chapter describes the control file syntax you use to configure SQL*Loader and to describe to SQL*Loader how to map your data to Oracle format. It provides detailed syntax diagrams and information about specifying datafiles, tables and columns, the location of data, the type and format of data to be loaded, and more.
This chapter describes the field list section of a SQL*Loader control file. The field list provides information about fields being loaded, such as position, datatype, conditions, and delimiters.
This chapter describes how to load column objects in various formats. It also discusses how to load object tables, REF
columns, LOB
s, and collections.
This chapter describes the differences between a conventional path load and a direct path load. A direct path load is a high-performance option that significantly reduces the time required to load large quantities of data.
This chapter presents case studies that illustrate some of the features of SQL*Loader. Some of the features demonstrated are the loading of variable-length data, fixed-format records, free-format files, multiple physical records as one logical record, and multiple tables, as well as performing direct path loads, and loading objects, collections, and REF
columns.
This chapter describes basic concepts about external tables.
This chapter describes the access parameters used to interface with the ORACLE_LOADER
access driver.
This chapter describes the ORACLE_DATAPUMP
access driver, including its parameters, and information about loading and unloading supported datatypes.
This chapter describes how to use the offline database verification utility, DBVERIFY.
This chapter describes how to use the DBNEWID utility to change the name or ID, or both, for a database.
This chapter describes the Metadata API, which you can use to extract and manipulate complete representations of the metadata for database objects.
This chapter describes the LogMiner utility, which you can use to query redo logs through a SQL interface.
This chapter describes how to use the original Export and Import utilities to write data from an Oracle database into transportable files, and then to read that data into an Oracle database. It discusses guidelines, export and import modes, and available parameters. It also provides examples of various types of export and import operations.
This appendix provides diagrams of the SQL*Loader syntax.
This appendix explains the symbols and conventions of the variant of Backus-Naur Form (BNF) used in text descriptions of syntax diagrams.
For more information, see these Oracle resources:
The Oracle Database documentation set, especially:
Some of the examples in this book use the sample schemas of the seed database, which is installed by default when you install Oracle Database. Refer to Oracle Database Sample Schemas for information about how these schemas were created and how you can use them yourself.
Oracle error message documentation is only available in HTML. If you only have access to the Oracle Database Documentation CD, you can browse the error messages by range. Once you find the specific range, use your browser's "find in page" feature to locate the specific message. When connected to the Internet, you can search for a specific error message using the error message search feature of the Oracle online documentation.
Printed documentation is available for sale in the Oracle Store at
http://oraclestore.oracle.com/
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/membership/
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/documentation/
This section describes the conventions used in the text and code examples of this documentation set. It describes:
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. | Oracle 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 Query the Use the |
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 Back up the datafiles and control files in the The Set the Connect as The |
lowercase italic monospace (fixed-width) font |
Lowercase italic monospace font represents placeholders or variables. | You can specify the parallel_clause .
Run |
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:
|
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. |
SQL> SELECT NAME FROM V$DATAFILE; NAME ------------------------------------ /fsl/dbs/tbs_01.dbf /fs1/dbs/tbs_02.dbf . . . /fsl/dbs/tbs_09.dbf 9 rows selected. |
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; |