Tải bản đầy đủ (.pdf) (538 trang)

oracle database 10g administration workshop ii

Bạn đang xem bản rút gọn của tài liệu. Xem và tải ngay bản đầy đủ của tài liệu tại đây (6.41 MB, 538 trang )

Oracle Database 10g:
Administration Workshop II
Student Guide
D17092GC10
Edition 1.0
March 2004
Applied
®
Copyright © 2004, Oracle. All rights reserved.
This documentation contains proprietary information of Oracle Corporation. It is
provided under a license agreement containing restrictions on use and disclosure and
is also protected by copyright law. Reverse engineering of the software is prohibited.
If this documentation is delivered to a U.S. Government Agency of the Department of
Defense, then it is delivered with Restricted Rights and the following legend is
applicable:
Restricted Rights Legend
Use, duplication or disclosure by the Government is subject to restrictions for
commercial computer software and shall be deemed to be Restricted Rights software
under Federal law, as set forth in subparagraph (c)(1)(ii) of DFARS 252.227-7013,
Rights in Technical Data and Computer Software (October 1988).
This material or any portion of it may not be copied in any form or by any means
without the express prior written permission of Oracle Corporation. Any other copying
is a violation of copyright law and may result in civil and/or criminal penalties.
If this documentation is delivered to a U.S. Government Agency not within the
Department of Defense, then it is delivered with “Restricted Rights,” as defined in
FAR 52.227-14, Rights in Data-General, including Alternate III (June 1987).
The information in this document is subject to change without notice. If you find any
problems in the documentation, please report them in writing to Education Products,
Oracle Corporation, 500 Oracle Parkway, Redwood Shores, CA 94065. Oracle
Corporation does not warrant that this document is error-free.
Oracle and all references to Oracle Products are trademarks or registered trademarks


of Oracle Corporation.
All other products or company names are used for identification purposes only, and
may be trademarks of their respective owners.
Authors
Janet Stern
James Womack
Technical Contributors
and Reviewers
Christine Jeal
Joel Goodman
Dairy Chan
Martin Jensen
Donna Keesling
Roman Niehoff
Srinivas Putrevu
Wolfgang Krueger
Dr. Sabine Teuber
Gerlinde Frenzen
John Watson
Lothar Auert
Andreas Reinhardt
Editor
Atanu Raychaudhuri
Publisher
Jobi Varghese
1 Introduction
Course Objectives 1-2
How DBAs Spend Their Time 1-3
Oracle Database 10g Manageability Goals 1-4
Database Management Challenges 1-5

Oracle Database 10g Solution: Self-Managing Database 1-6
How Oracle Database 10g DBAs Spend Their Time 1-7
Student Preface 1-8
2 Using Globalization Support
Objectives 2-2
Globalization Support Features 2-3
Encoding Schemes 2-4
Database Character Sets and National Character Sets 2-7
Datetimes with Timezones 2-9
Configuring the Database Local Timezone 2-10
Configuring Datetime Formats 2-11
Using Timezones 2-12
Specifying Language-Dependent Behavior 2-13
Specifying Language-Dependent Behavior for the Server 2-14
Language and Territory Dependent Parameters 2-15
Other NLS Server Parameters 2-17
Specifying Language-Dependent Behavior for the Session 2-18
Locale Variants 2-21
Using NLS Parameters in SQL Functions 2-22
Linguistic Sorting 2-25
Using Linguistic Sorting 2-27
Sorts That Are Not Case or Accent Sensitive 2-29
Linguistic Comparisons 2-30
Linguistic Index Support 2-31
Customizing Linguistic Sorting 2-32
Oracle Locale Builder 2-33
Character Set Scanner Utilities 2-34
Data Conversion Between Client and Server Character Sets 2-36
NLS Data Conversion with Oracle Utilities 2-37
NLS Data Conversion with Data Pump 2-39

Obtaining Character Set Information 2-40
Obtaining NLS Parameter Information 2-41
Obtaining NLS Settings Information 2-42
Summary 2-43
Practice 2 Overview: Using Globalization Support Features 2-44
Contents
3 Controlling Access to the Oracle Listener
Objectives 3-2
Listener Password Authentication 3-3
Setting Listener Password 3-4
Setting Listener Password with Net Manager 3-5
Set Password with lsnrctl Utility 3-6
Controlling Database Access 3-7
Oracle Net Services External Procedures 3-8
Overview of the EXTPROC Agent 3-9
PL/SQL Calling a C External Procedure 3-10
Default Configuration for External Procedure Calls 3-11
Modifying the Configuration for External Procedure Calls 3-13
Remove Default EXTPROC Entry 3-14
Configure a Dedicated Listener for External Procedure Calls 3-16
Summary 3-20
Practice 3 Overview: Controlling Access to the Listener 3-21
4 Enabling Distributed Transactions
Objectives 4-2
Oracle Net Services Review 4-3
Connecting to an Oracle Database 4-4
Client Application Connectivity to the Oracle Server 4-5
Server-Server Connectivity 4-6
Types of Database Links 4-7
Creating Database Links 4-8

Dropping Links 4-10
Data Dictionary Views 4-11
Remote Query 4-12
Executing a Remote Query 4-13
Distributed Query 4-14
Executing a Distributed Query 4-15
Distributed and Remote Transactions 4-16
In-Doubt Transactions 4-17
Summary 4-19
5 Configuring Recovery Manager
Objectives 5-2
Recovery Manager Features 5-3
Recovery Manager Components 5-5
Media Management 5-7
Using a Flash Recovery Area with RMAN 5-9
Setting Parameters for RMAN 5-10
RMAN Usage Considerations 5-12
Connection Types with RMAN 5-13
Starting RMAN 5-14
ii
Additional RMAN Command Line Arguments 5-15
Configuring Persistent Settings for RMAN 5-16
Configuring RMAN Settings Using EM 5-17
Managing Persistent Settings 5-18
Channel Allocation 5-19
Automatic and Manual Channel Allocation 5-20
Channel Control Options 5-21
Summary 5-23
Practice 5 Overview: Configuring RMAN 5-24
6 Using Recovery Manager

Objectives 6-2
Issuing Recovery Manager Commands 6-3
RMAN Command Overview 6-5
RMAN Commands 6-6
Job Command: Example 6-7
The BACKUP Command 6-8
Backup Constraints 6-9
Parallelization of Backup Sets 6-10
Compressed Backups 6-12
Image Copy 6-13
Tags for Backups and Image Copies 6-15
BACKUP Options 6-16
Backing Up Archived Redo Logs 6-18
Copying the Whole Database 6-19
Making Incremental Backups 6-20
Incremental Backup: Example 6-22
Block Change Tracking 6-23
Enabling Block Change Tracking 6-24
Incrementally Updating Backups 6-25
LIST Command Operations 6-26
The REPORT Command 6-27
The REPORT NEED BACKUP Command 6-28
REPORT NEED BACKUP: Examples 6-29
REPORT OBSOLETE and DELETE OBSOLETE 6-30
Managing Backups with EM 6-31
RMAN Dynamic Views 6-32
Monitoring RMAN Backups 6-34
Summary 6-36
Practice 6 Overview: Using RMAN 6-37
iii

7 Diagnostic Sources
Objectives 7-2
Diagnostic Files 7-3
The Alert Log 7-4
What Is in the alert.log File 7-5
Viewing Recent Alert Log Entries 7-6
Alert Models Architecture 7-7
Server-Generated Alert Types 7-8
Viewing Alerts with Enterprise Manager 7-9
Alerts Notification 7-11
Alert Log Monitoring Configuration 7-12
Editing Thresholds 7-13
Viewing Initialization Parameters 7-14
Trace Files 7-15
Specifying the Location of Trace Files 7-16
Controlling Trace File Size 7-17
Controlling Trace File Writes 7-18
Using Enterprise Manager to Enable and View SQL Tracing 7-19
System Log Files 7-20
Summary 7-21
Practice 7 Overview: Diagnosing Problems 7-22
8 Recovering from Non-Critical Losses
Objectives 8-2
Recovery of Non-Critical Files 8-3
Creating New Temporary Tablespace 8-4
Creating a New Control File 8-5
Control File Autobackups 8-7
Recreating Redo Log Files 8-9
Recovering an Index Tablespace 8-12
Recovery Steps 8-13

Server Managed Recovery: RESTORE and RECOVER Commands 8-14
User-Managed Recovery Procedures: RECOVER Command 8-15
Summary 8-16
Practice 8 Overview: Recreating the Control File 8-17
iv
9 Incomplete Recovery
Objectives 9-2
Incomplete Recovery Overview 9-3
Situations Requiring Incomplete Recovery 9-4
Types of Incomplete Recovery 9-5
Incomplete Recovery Best Practices 9-7
Using RECOVER for Incomplete Recovery 9-9
UNTIL TIME Recovery Example 9-10
UNTIL TIME Recovery Steps 9-11
Cancel-Based Recovery: Example 9-13
Incomplete Recovery and the Alert Log 9-15
Incomplete Recovery of a Database Using RMAN 9-16
RMAN Incomplete Recovery UNTIL TIME: Example 9-17
RMAN Incomplete Recovery UNTIL SEQUENCE: Example 9-19
Recovery Using Enterprise Manager 9-20
Summary 9-26
Practice 9 Overview: Incomplete Recovery 9-27
10 Flashback Database
Objectives 10-2
Flashback Any Error 10-3
Flashback Technology Benefits 10-4
When To Use Flashback Technology 10-5
Flashback Database Overview 10-6
Flashback Database Reduces Restore Time 10-7
Flashback Database Architecture 10-8

Configuring Flashback Database 10-9
Configure Flashback Database with EM 10-10
Monitoring Flashback Database 10-12
Monitoring Flashback Database with EM 10-14
Monitoring Flash Recovery Area with EM 10-15
Best Practices for the Database and Flash Recovery Area 10-16
Backing Up the Flash Recovery Area 10-17
Flash Recovery Area Space Usage 10-18
Flashback Database Examples 10-19
Flashback Database with EM 10-20
Flashback Database Using EM 10-22
Excluding Tablespaces from Flashback Database 10-23
Flashback Database Considerations 10-24
Summary 10-25
Practice 10 Overview: Flashback Database 10-26
v
11 Recovering from User Errors
Objectives 11-2
Flashback Time Navigation 11-3
Flashback Drop Overview 11-4
Recycle Bin 11-5
Querying the Recycle Bin 11-6
Flashback Dropped Tables Using EM 11-8
Restoring Objects from the Recycle Bin 11-9
Recycle Bin Automatic Space Reclamation 11-10
Recycle Bin Manual Space Reclamation 11-12
Bypassing the Recycle Bin 11-14
Querying Dropped Tables 11-15
Flashback Drop Considerations 11-16
Flashback Versions Query Overview 11-17

Flashback Versions Query Using EM 11-18
Flashback Versions Query Syntax 11-19
Flashback Versions Query Example 11-20
Flashback Versions Query Considerations 11-21
Flashback Transaction Query Overview 11-22
Querying FLASHBACK_TRANSACTION_QUERY 11-23
Using Flashback Versions Query and Flashback Transaction Query 11-24
Flashback Transaction Query Using EM 11-25
Flashback Transaction Query Considerations 11-26
Flashback Table Overview 11-27
Using EM to Flashback Tables 11-28
Flashback Table Example 11-29
Rolling Back a Flashback Table Operation 11-30
Flashback Table Considerations 11-31
Guaranteed Undo Retention 11-32
SCN and Time Mapping Enhancements 11-33
Summary 11-34
Practice 11 Overview: Recovering from User Errors 11-35
12 Dealing With Database Corruption
Objectives 12-2
What Is Block Corruption? 12-3
Block Corruption Symptoms: ORA-1578 12-4
DBVERIFY Utility 12-5
Interpreting DBVERIFY 12-6
The ANALYZE Command 12-8
Initialization Parameter DB_BLOCK_CHECKING 12-9
How to Handle Corruptions 12-10
The DBMS_REPAIR Package 12-12
Using DBMS_REPAIR 12-13
vi

Block Media Recovery (BMR) 12-17
The BLOCKRECOVER Command 12-18
RMAN BMR Interface 12-19
Examples of BLOCKRECOVER 12-20
Which Object Is Corrupted? 12-22
Summary 12-23
Practice 12 Overview: Dealing with Database Corruption 12-24
13 Optimizing Database Performance
Objectives 13-2
Advisory Framework Overview 13-3
Database Control and Advisors 13-5
Typical Advisor Tuning Session 13-6
Manually Invoking ADDM 13-7
Application Tuning Challenges 13-8
SQL Tuning Advisor Overview 13-9
SQL Tuning Advisor Options and Recommendations 13-10
Using the SQL Tuning Advisor 13-11
Using the SQL Access Advisor 13-13
Using the Memory Advisor 13-15
Segment Advisor Overview 13-16
Segment Advisor 13-17
Growth Trend Report 13-18
Segment Resource Estimation 13-19
The Undo Management Page 13-20
The Undo Advisor Page 13-21
What Is Automatic Storage Management? 13-22
ASM Key Features and Benefits 13-23
ASM Concepts 13-24
ASM General Architecture 13-25
ASM Instance Creation 13-27

ASM Instance Initialization Parameters 13-28
Accessing an ASM Instance 13-29
ASM Home Page 13-30
ASM Performance Page 13-31
ASM Configuration Page 13-32
Starting Up an ASM Instance 13-33
Shutting Down an ASM Instance 13-34
ASM Disk Groups 13-35
ASM Administration Page 13-36
Create Disk Group Page 13-37
ASM Files 13-38
ASM Filenames 13-39
vii
ASM File Name Mapping 13-40
SQL Commands and File Naming 13-41
DBCA and Storage Options 13-42
Migrating Your Database to ASM Storage 13-43
Summary 13-44
Practice 13 Overview: Optimizing Database Performance 13-45
14 Using Materialized Views
Objectives 14-2
Materialized Views 14-3
Refreshing Materialized Views 14-4
Materialized View Logs 14-6
Primary Key Materialized Views 14-7
Creating Materialized Views 14-8
Updatable Materialized Views 14-9
Monitoring Materialized View Refresh 14-10
Refresh Job Errors 14-11
Monitoring Refresh Operations 14-12

Additional Distributed Data Technologies 14-13
Summary 14-15
15 Managing Resources
Objectives 15-2
Overview 15-3
Database Resource Manager Concepts 15-4
Using Sub-Plans to Limit CPU Utilization 15-5
Limiting CPU Utilization: Example 15-7
Resource Manager Configurations 15-8
Active Session Pool Mechanism 15-10
Setting the Active Session Pool 15-11
Automatic Consumer Group Switching 15-13
Configuring Consumer Group Switching 15-16
Adaptive Consumer Group Mapping 15-17
Creating a Mapping Using DBMS_RESOURCE_MANAGER 15-18
Assigning Priorities Using DBMS_RESOURCE_MANAGER 15-19
The Initial Plan: SYSTEM_PLAN 15-20
Creating a New Resource Plan 15-21
Oracle Enterprise Manager: Resource Manager 15-23
Creating a Simple Plan 15-24
Creating a Complex Plan 15-25
Resource Allocation Methods for Resource Plans 15-26
Comparison of EMPHASIS and RATIO 15-28
Creating Resource Consumer Groups 15-30
viii
Assigning Users to Consumer Groups 15-32
Resource Allocation Methods for Consumer Groups 15-33
Administering the Resource Manager 15-34
Assigning Resource Manager Privileges 15-35
Setting the Resource Plan for an Instance 15-36

Viewing Resource Consumer Groups 15-37
Changing a Consumer Group Within a Session 15-38
Changing Consumer Groups for Sessions 15-39
Database Resource Manager Information 15-40
Resource Plan Directives 15-41
Monitoring the Resource Manager 15-43
Summary 15-46
Practice 15 Overview: Using the Resource Manager 15-47
16 Automating Tasks with the Scheduler
Objectives 16-2
Scheduling Needs 16-3
Scheduler Concepts 16-4
Privileges for Scheduler Components 16-6
Creating a Scheduler Job 16-8
Creating a Scheduler Job: Example 16-9
Setting the Repeat Interval for a Job 16-10
Calendaring Expressions 16-11
Using Scheduler Programs 16-12
Creating a Program Using EM 16-13
Specifying Schedules for a Job 16-14
Creating and Using Schedules 16-15
Using EM to Create Schedules 16-16
Advanced Scheduler Concepts 16-17
Creating a Job Class 16-18
Job Logging 16-20
Creating a Window 16-21
Prioritizing Jobs Within a Window 16-23
Enabling and Disabling Scheduler Components 16-25
Managing Jobs 16-26
Managing Programs 16-27

Managing Programs with EM 16-28
Managing Schedules 16-29
Managing Windows 16-30
Window Priority 16-32
Managing Attributes of Scheduler Components 16-33
Managing Attributes of the Scheduler 16-35
ix
Viewing Job Execution Details 16-36
Viewing Job Logs 16-37
Purging Job Logs 16-38
Data Dictionary Views 16-40
Summary 16-41
Practice 16 Overview: Automating Tasks with the Scheduler 16-42
17 Advanced Tools and Techniques
Objectives 17-2
Using SQL to Generate Scripts 17-3
Example: Compiling Invalid Objects 17-4
What Is a Procedure? 17-5
PL/SQL Procedures 17-6
Using IN and OUT Parameters 17-7
Using Native Dynamic SQL 17-9
The EXECUTE IMMEDIATE Statement 17-10
Dynamic SQL Using EXECUTE IMMEDIATE 17-12
Dynamic SQL Example 17-13
External Tables 17-14
External Tables and the Oracle Database 17-15
External Tables: Example 17-16
Retrieving User Context Attributes 17-17
Resumable Statements 17-19
Using Resumable Space Allocation 17-20

Resuming Suspended Statements 17-22
Summary 17-24
Practice 17 Overview: Using Dynamic SQL 17-25
18 Workshop
Objectives 18-2
Workshop Methodology 18-3
Business Requirements 18-5
Database Configuration 18-6
Simulated Application 18-7
Method for Resolving Database Issues 18-8
Summary 18-10
Practice 18 Overview: Workshop Setup 18-11
Appendix A: Solutions
Appendix B: Basic Linux and vi Commands
Appendix C: Acronyms and Terms
x
Copyright © 2004, Oracle. All rights reserved.
Introduction
Oracle Database 10g: Administration Workshop II 1-2
Copyright © 2004, Oracle. All rights reserved.
1-2
Course Objectives
In this course, you will gain hands-on experience with:
• Advanced backup and recovery concepts
• Implementing a backup and recovery strategy
• Employing database monitoring practices
• Basic database tuning
• Scheduling of tasks
Oracle Database 10g: Administration Workshop II 1-3
Copyright © 2004, Oracle. All rights reserved.

1-3
How DBAs Spend Their Time
Load data: 6%
Maintain
software: 6%
Install: 6%
Create and
configure: 12%
Manage database
system: 55%
How Database Administrators (DBAs) Spend Their Time
The bulk of a DBA’s time is spent performing ongoing management. Ongoing management
tasks include:
• SQL and application tuning
• System resource tuning
• Space and object management
• Backup and recovery
• Storage management
Oracle Database 10g: Administration Workshop II 1-4
Copyright © 2004, Oracle. All rights reserved.
1-4
• Automatic versus manual
• Intelligence versus data
• Adaptive versus oversized
• Integrated versus third-party
• Preventive versus corrective
• Act-and-succeed versus trial-and-error
Reduce failure costs
Reduce capital expenditures
Oracle Database 10g Manageability Goals

Reduce administration costs
Oracle Database 10g Manageability Goals
Oracle Database 10g is a giant step toward the Oracle vision of creating a self-aware, self-
learning, and completely self-managing database. A huge development effort has gone into
simplifying every aspect of Oracle Database 10g administration with the dual objectives of
enhancing administrator productivity and reducing operational costs.
Oracle Database 10g: Administration Workshop II 1-5
Copyright © 2004, Oracle. All rights reserved.
1-5
Database Management Challenges
Application
and SQL
management
Storage
management
Backup and
recovery
management
System
resource
management
Space
management
?
?
?
?
?
Database Management Challenges
With previous releases of the Oracle Database, a good portion of a DBA’s time was spent on

monitoring database system health, identifying bottlenecks, and improving system performance.
Some of the tasks included:
• Application and SQL management: Creating indexes and collecting optimizer statistics
• System resource management: Monitoring CPU utilization and sizing the various
database buffers
• Space management: Sizing the various database files and monitoring space utilization
within segments
• Backup and recovery management: Monitoring the mean time to recover the database,
planning for disaster recovery, and backing up the database
• Storage management: Configuring disks, monitoring I/O bandwidth, and determining the
stripe size
Oracle Database 10g: Administration Workshop II 1-6
Copyright © 2004, Oracle. All rights reserved.
1-6
Oracle Database 10g Solution:
Self-Managing Database
Application
and SQL
management
Storage
management
Backup and
recovery
management
System
resource
management
Space
management
Fix Advise

AlertMonitor
Common
manageability
infrastructure
Automatic
management
Enterprise
Manager 10g
Oracle Database 10g Solution: Self-Managing Database
Oracle Database 10g can now automatically inform you of performance and resource allocation
problems. In addition to providing suggestions for fixing these problems, Oracle Database 10g
can also automatically fix the problems for you.
The second part of Oracle Corporation’s manageability strategy focuses on making the
management of data centers easier, scalable, and more effective. Oracle Enterprise Manager 10g
provides this solution. Enterprise Manager is a single, integrated solution for administering and
monitoring all applications and systems based on the Oracle technology stack. The next-
generation, HTML-based Enterprise Manager 10g provides the ability to seamlessly manage
hundreds of systems located across organizational and geographical boundaries from a single
point of control. Built with robust functionality for managing both small and large sets of
systems, Enterprise Manager 10g automates critical operations to reduce task time and the risk
of errors, which increases as the number of systems goes up. Its robust grouping and task-
automation functionalities provide core features that enable reliable, rapid, and secure
automation of traditionally time-consuming, error-prone tasks, such as application performance
management, policy-based standardization, and system provisioning.
Oracle Database 10g: Administration Workshop II 1-7
Copyright © 2004, Oracle. All rights reserved.
1-7
How Oracle Database 10g DBAs
Spend Their Time
Load data: 3%

Maintain
software: 3%
Install: 3%
Create and
configure: 6%
Manage database
system: 25%
Proactive
and strategic
planning:
45+%
Scale to the Grid
How Oracle Database 10g DBAs Spend Their Time
As the demand for database uptime continues to increase, so does the rate of growth in the
average database size. These trends result in what some experts are calling the “management
gap.” The doubling of both disk density and database size every few years is not being matched
by a doubling of DBA staff in the same time period.
Therefore, DBAs are being asked to manage more (and larger) databases with the same staff. For
this reason, they need tools that enable them to work more efficiently and manage more with
fewer resources. With Oracle Database 10g, DBAs:
• Think and act more proactively and strategically
• Are application-aware and business-sensitive
• Support larger databases with more users for more mission-critical applications
• Can consolidate, centralize, and globalize
• Require and provide more education
• Are even more important and valuable
Oracle Database 10g: Administration Workshop II 1-8
Copyright © 2004, Oracle. All rights reserved.
1-8
Student Preface

Even if topics might not seem to be relevant to you
now, your job functions may change due to:
• New products or methods
• Changes in your employment
• Changes in corporate structure
• Enhancements in applications
Student Preface
As you progress through this course, you may encounter a number of topics that do not seem
relevant for you at the present time. However, you should remember that information technology
is an industry in which about 50 percent of your skills and knowledge today will be obsolete in a
year or so. Features that are not of current interest could become valuable to you for a number of
reasons:
• Your company introduces a new product or business method that requires new database
functionality.
• You choose to advance your career by moving to a different group or company that
requires you to use unfamiliar features.
• Your company business changes due to a merger or acquisition.
• A maintenance window for an old application allows developers to incorporate features
that were not available when the application was first written.
The goal for this course is to teach you database administration skills that take you beyond basic
configuration and monitoring tasks. This course covers a variety of features and techniques that
you can employ to optimize database performance, increase data availability, and enhance your
own productivity.
Co
py
ri
g
ht
©
2004, Oracle. All ri

g
hts reserved.
Using Globalization Support
Oracle Database 10g: Administration Workshop II 2-2
2-2
Co
py
ri
g
ht
©
2004, Oracle. All ri
g
hts reserved.
Objectives
After completing this lesson, you should be able to:
• Customize language-dependent behavior for the
database and individual sessions
• Specify different linguistic sorts for queries
• Retrieve data that matches a search string
ignoring case or accent differences
• Obtain Globalization support configuration
information
Oracle Database 10g: Administration Workshop II 2-3
2-3
Co
py
ri
g
ht

©
2004, Oracle. All ri
g
hts reserved.
Globalization Support Features
• Language support
• Territory support
• Character set support
• Linguistic sorting
• Message support
• Date and time formats
• Numeric formats
• Monetary formats
Globalization Support Features
Different countries and geographies dictate different cultural conventions that directly
affect data formats. Globalization Support ensures that utilities and error messages, sort
order, date, time, monetary, numeric, and calendar conventions automatically adapt to the
native language. Users can interact, store, process, and retrieve data in their native
languages and formats:
• Time zones can be used to support daylight savings time.
• National calendars such as Gregorian, Japanese, Imperial, and Thai Buddha are
supported.
• Currency symbols reflect the local economy and ISO conventions. Credit and debit
symbols also differ from location to location.
Oracle Database currently supports 63 languages, 92 territories, 64 linguistic sorts (51
monolingual and 13 multilingual), and 257 encoded character sets (41 Asian, 162
European, 50 Middle Eastern, and 4 Universal).
The language-dependent operations are controlled by a number of parameters and
environment variables on both the client and the server sides. The server and the client
may run in the same or different locations. When the client and the server use different

character sets, the Oracle Database handles character set conversion automatically.
Oracle Database 10g: Administration Workshop II 2-4
2-4
Co
py
ri
g
ht
©
2004, Oracle. All ri
g
hts reserved.
Encoding Schemes
Oracle Database supports different classes of
character encoding schemes:
• Single-byte character sets
– 7-bit
– 8-bit
• Fixed-width multibyte character sets
• Varying-width multibyte character sets
• Universal character sets, such as Unicode
Encoding Schemes
When computer systems process characters, they use numeric codes instead of the
graphical representation of the character. An encoded character set maps numeric codes to
characters that a computer or terminal can display and receive. Oracle Database supports
most national, international, and vendor-specific encoded character set standards.
Different character sets support different character repertoires. Because character sets are
typically based on a particular writing script, they can support more than one language.
However, script-based character sets are restricted in the sense that they are limited to
groups of languages based on similar scripts. Universal character sets encompass most

major scripts of the modern world and provide a more useful solution to multilingual
support.
Oracle Database provides different classes of encoding schemes:
•Single-byte
• Fixed-width multibyte
• Varying-width multibyte
• Universal
Oracle Database 10g: Administration Workshop II 2-5
Encoding Schemes (continued)
Single-byte character sets
In a single-byte character set, each character occupies one byte. Single-byte 7-bit encoding
schemes can define up to 128 (2
7
) characters; single-byte 8-bit encoding schemes can
define up to 256 (2
8
) characters.
Examples of single-byte schemes
7-bit character set:
• American Standard Code for Information Interchange (ASCII) 7-bit American
(US7ASCII)
• ASCII 7-bit Yugoslavian (YUG7ASCII)
• DEC VT100 7-bit French (F7DEC)
8-bit character set:
• International Organization for Standards (ISO) 8859-1 West European
(WE8ISO8859P1)
• DEC 8-bit West European (WE8DEC)
• Extended Binary Coded Decimal Interchange Code (EBCDIC) Code Page 1144 8-bit
Italian (I8EBCDIC1144)
Note: ASCII-based character sets are supported only on ASCII-based platforms.

Similarly, you can use an EBCDIC-based character set only on EBCDIC-based
platforms.
Fixed-width multibyte character sets
In a fixed-width multibyte encoding scheme, each character is represented by a fixed
number of bytes. The number of bytes is at least two in a multibyte encoding scheme.
Only one fixed-width multibyte character set is supported and it is the Unicode 3.2 UTF-
16 Universal character set (AL16UTF16).
Varying-width multibyte character sets
A varying-width multibyte character set is represented by one or more bytes per character.
Multibyte character sets are commonly used for Asian language support. Some multibyte
encoding schemes use the value of the most significant bit to indicate if a byte represents a
single byte or is part of a series of bytes representing a character. However, other character
encoding schemes differentiate single-byte from multibyte characters. A shift-out control
code, sent by a device, indicates that any successive bytes are double-byte characters until
a shift-in code is encountered. Shift-sensitive encoding schemes are used primarily on
IBM platforms.
Examples of varying-width multibyte schemes
• Shift-JIS 16-bit Japanese (JA16SJIS)
• HP CCDC 16-bit Traditional Chinese (ZHT16CCDC)
• MS Windows Code Page 950 with Hong Kong Supplementary Character Set
HKSCS-2001 (ZHT16HKSCS)
• Unicode 3.2 UTF-8 Universal character set (AL32UTF8)

×