San Francisco ◆ London Foundations Oracle Database Bob Bryla 4372cFM.fm Page i Monday, August 16, 2004 6:52 PM Associate Publisher: Neil Edde Acquisitions and Developmental Editor: Maureen Adams Production Editor: Susan Berge Copyeditor: Linda S. Recktenwald Compositor: Craig Woods, Happenstance Type-O-Rama Graphic Illustrator: Jeff Wilson, Happenstance Type-O-Rama Proofreaders: Amy J. Rasmussen, Nancy Riddiough Indexer: Ted Laux Book Designer: Judy Fung Cover Designer: Ingalls + Associates Cover Photo: Jerry Driendl, Taxi Copyright © 2004 SYBEX Inc., 1151 Marina Village Parkway, Alameda, CA 94501. World rights reserved. No part of this publication may be stored in a retrieval system, transmitted, or reproduced in any way, including but not limited to photo- copy, photograph, magnetic, or other record, without the prior agreement and written permission of the publisher. An earlier version of this book was published under the title Oracle9i DBA JumpStart © 2003 SYBEX Inc. Library of Congress Card Number: 2004109313 ISBN: 0-7821-4372-5 SYBEX and the SYBEX logo are either registered trademarks or trademarks of SYBEX Inc. in the United States and/or other countries. Screen reproductions produced with FullShot 99. FullShot 99 © 1991-1999 Inbit Incorporated. All rights reserved. FullShot is a trademark of Inbit Incorporated. Internet screen shot(s) using Microsoft Internet Explorer 6 reprinted by permission from Microsoft Corporation. TRADEMARKS: SYBEX has attempted throughout this book to distinguish proprietary trademarks from descriptive terms by fol- lowing the capitalization style used by the manufacturer. The author and publisher have made their best efforts to prepare this book, and the content is based upon final release software whenever possible. Portions of the manuscript may be based upon pre-release versions supplied by software manufacturer(s). The author and the publisher make no representation or warranties of any kind with regard to the completeness or accuracy of the con- tents herein and accept no liability of any kind including but not limited to performance, merchantability, fitness for any particular purpose, or any losses or damages of any kind caused or alleged to be caused directly or indirectly from this book. Manufactured in the United States of America 10 9 8 7 6 5 4 3 2 1 4372cFM.fm Page ii Monday, August 16, 2004 6:52 PM For MCL and the kids. 4372cFM.fm Page iii Monday, August 16, 2004 6:52 PM Acknowledgments I couldn’t have written this book without the help of many talented and creative people. I would like to thank Neil Edde, associate publisher, and Maureen Adams, acquisitions editor, for recognizing the need for an introductory Oracle DBA text. Many thanks to production editor Susan Berge and copyeditor Linda Recktenwald for their valuable advice. Thanks also to technical editor Betty MacEwen for her attention to detail and helpful suggestions throughout the book. The nature of this book required a great deal of artwork. Jeff Wilson and the rest of Happenstance Type-O-Rama did an excellent job of creating artwork that was appropriate for the book. They say a picture is worth a thousand words, and their art is an essential part of this book. Somehow they were able to decipher my Microsoft Word cave drawings and turn them into real graphics. Many of my professional colleagues at both Lands’ End and Greenbrier & Russel were a source of both inspi- ration and guidance. Also, regards to my long-lost friend from fourth grade, Janice, who I’m sure is a DBA out there somewhere. Finally, I want to thank my family for all of their support and patience. I was still able to give the kids a bath, play some cards, and read books at bedtime, even with the short deadlines. The journey wouldn’t have been half the fun without them. 4372cFM.fm Page iv Monday, August 16, 2004 6:52 PM Contents Introduction xiii Chapter 1 Relational Database Concepts 1 Are Spreadsheets Like Databases? . . . . . . . . . . . . . . . . . . . 2 Relational Databases . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 Tables, Rows, and Columns . . . . . . . . . . . . . . . . . . . . . 4 Primary Keys, Datatypes, and Foreign Keys . . . . . . . . . 4 Data Modeling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 Object-Relational Databases . . . . . . . . . . . . . . . . . . . . . . . 8 Abstraction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 Methods and Encapsulation . . . . . . . . . . . . . . . . . . . . . 9 Inheritance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 Object-Relational Support . . . . . . . . . . . . . . . . . . . . . . 10 Terms to Know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10 Review Questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11 Chapter 2 SQL*Plus and iSQL*Plus Basics 13 Some SQL Formalities . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 Tools for Running SQL . . . . . . . . . . . . . . . . . . . . . . . . . . 14 SQL*Plus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14 iSQL*Plus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17 SQL*Plus Worksheet . . . . . . . . . . . . . . . . . . . . . . . . . . 20 Third-Party Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 ODBC/JDBC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 OCI . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 The Ubiquitous SELECT Statement . . . . . . . . . . . . . . . . . 23 Column Specification . . . . . . . . . . . . . . . . . . . . . . . . . 24 Column Renaming . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 Duplicate Removal . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 Expressions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 DML for Making Changes . . . . . . . . . . . . . . . . . . . . . . . . 29 The UPDATE Statement . . . . . . . . . . . . . . . . . . . . . . . 29 The INSERT Statement . . . . . . . . . . . . . . . . . . . . . . . . 31 The DELETE Statement . . . . . . . . . . . . . . . . . . . . . . . 32 The MERGE Statement . . . . . . . . . . . . . . . . . . . . . . . . 33 DDL for Handling Database Objects . . . . . . . . . . . . . . . . 34 The CREATE Statement . . . . . . . . . . . . . . . . . . . . . . . 34 The ALTER Statement . . . . . . . . . . . . . . . . . . . . . . . . 36 The DROP Statement . . . . . . . . . . . . . . . . . . . . . . . . . 37 4372cFM.fm Page v Monday, August 16, 2004 6:52 PM vi Contents The RENAME Statement . . . . . . . . . . . . . . . . . . . . . . 37 The TRUNCATE Statement . . . . . . . . . . . . . . . . . . . . 38 DCL for Handling Privileges . . . . . . . . . . . . . . . . . . . . . . 39 The GRANT Statement . . . . . . . . . . . . . . . . . . . . . . . . 39 The REVOKE Statement . . . . . . . . . . . . . . . . . . . . . . . 40 Terms to Know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40 Review Questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41 Chapter 3 Oracle Database Functions 43 Query Basics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 The DUAL Table . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44 NULL s: What, When, Why, and How . . . . . . . . . . . . 46 String Literals and Concatenating Strings . . . . . . . . . . 47 Numeric Literals . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48 Operators and Operator Precedence . . . . . . . . . . . . . . 48 Built-In Single-Row Functions . . . . . . . . . . . . . . . . . . . . . 49 String Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50 Numeric Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . 53 Date Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56 Conversion Functions . . . . . . . . . . . . . . . . . . . . . . . . . 58 General Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61 User-Defined Functions . . . . . . . . . . . . . . . . . . . . . . . . . . 63 Terms to Know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66 Review Questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67 Chapter 4 Restricting, Sorting, and Grouping Data 69 The WHERE Clause . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70 Comparison Conditions . . . . . . . . . . . . . . . . . . . . . . . . 71 AND , OR , and NOT . . . . . . . . . . . . . . . . . . . . . . . . . 72 BETWEEN , IN , and LIKE . . . . . . . . . . . . . . . . . . . . . 75 IS NULL and IS NOT NULL . . . . . . . . . . . . . . . . . . . 79 The ORDER BY Clause . . . . . . . . . . . . . . . . . . . . . . . . . . 81 Group Functions and the GROUP BY Clause . . . . . . . . . 83 Group Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 84 The GROUP BY Clause . . . . . . . . . . . . . . . . . . . . . . . 85 Using NVL with Group Functions . . . . . . . . . . . . . . . . 87 The HAVING Clause . . . . . . . . . . . . . . . . . . . . . . . . . 88 Terms to Know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 90 Review Questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91 Chapter 5 Using Multiple Tables 93 Join Syntax: Out with the Old and In with the New (SQL:1999) . . . . . . . . . . . . . . . . . . . . . . . . . . . 94 4372cFM.fm Page vi Monday, August 16, 2004 6:52 PM Contents vii Equijoins . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94 Pre-Oracle9 i Equijoin Syntax . . . . . . . . . . . . . . . . . . . 94 Oracle9 i Equijoin Syntax . . . . . . . . . . . . . . . . . . . . . . . 97 Non-equijoins . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101 Pre-Oracle9 i Non-equijoin Syntax . . . . . . . . . . . . . . . 101 Oracle9 i Non-equijoin Syntax . . . . . . . . . . . . . . . . . . 102 Outer Joins . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103 Pre-Oracle9 i Outer Join Syntax . . . . . . . . . . . . . . . . . 103 Oracle9 i Outer Join Syntax . . . . . . . . . . . . . . . . . . . . 107 Self-Joins . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 110 Pre-Oracle9 i Self-Join Syntax . . . . . . . . . . . . . . . . . . 110 Oracle9 i Self-Join Syntax . . . . . . . . . . . . . . . . . . . . . . 111 Cartesian Products: The Black Sheep of the Family . . . . 112 Pre-Oracle9 i Cartesian Product Syntax . . . . . . . . . . . 112 Oracle9 i Cartesian Product Syntax . . . . . . . . . . . . . . 113 Terms to Know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114 Review Questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 115 Chapter 6 Advanced SQL Queries 117 Subqueries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 118 Single-Row Subqueries . . . . . . . . . . . . . . . . . . . . . . . 118 Multiple-Row Subqueries . . . . . . . . . . . . . . . . . . . . . 119 Correlated Subqueries . . . . . . . . . . . . . . . . . . . . . . . . 121 Multiple-Column Subqueries . . . . . . . . . . . . . . . . . . . 123 Set Operators . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 124 UNION and UNION ALL . . . . . . . . . . . . . . . . . . . . 124 INTERSECT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 129 MINUS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 130 ROLLUP and CUBE . . . . . . . . . . . . . . . . . . . . . . . . . . . 133 ROLLUP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 134 CUBE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 135 Terms to Know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 137 Review Questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 138 Chapter 7 Logical Consistency 139 Constraints . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 140 NOT NULL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 140 CHECK . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 142 UNIQUE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144 PRIMARY KEY . . . . . . . . . . . . . . . . . . . . . . . . . . . . 145 FOREIGN KEY . . . . . . . . . . . . . . . . . . . . . . . . . . . . 147 Transaction Processing . . . . . . . . . . . . . . . . . . . . . . . . . . 150 The COMMIT Statement . . . . . . . . . . . . . . . . . . . . . 151 The ROLLBACK Statement . . . . . . . . . . . . . . . . . . . 152 The SAVEPOINT Statement . . . . . . . . . . . . . . . . . . . 152 4372cFM.fm Page vii Monday, August 16, 2004 6:52 PM viii Contents Terms to Know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 153 Review Questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 154 Chapter 8 Installing Oracle and Creating a Database 155 Oracle Components Overview . . . . . . . . . . . . . . . . . . . . 156 Logical Storage Structures . . . . . . . . . . . . . . . . . . . . . 156 Physical Storage Structures . . . . . . . . . . . . . . . . . . . . 158 Oracle Memory Structures . . . . . . . . . . . . . . . . . . . . . 160 Background Processes . . . . . . . . . . . . . . . . . . . . . . . . 162 Installing Oracle Software . . . . . . . . . . . . . . . . . . . . . . . 163 Using the Oracle Universal Installer . . . . . . . . . . . . . . 163 Using the Oracle Enterprise Manager Tools . . . . . . . . 167 Creating an Oracle Database . . . . . . . . . . . . . . . . . . . . . 169 Disk and Memory Requirements . . . . . . . . . . . . . . . . 169 Using the Database Configuration Assistant . . . . . . . 169 Terms to Know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 179 Review Questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 180 Chapter 9 Reporting Techniques 181 iSQL*Plus Configuration . . . . . . . . . . . . . . . . . . . . . . . . 182 Interface Configuration . . . . . . . . . . . . . . . . . . . . . . . 184 Script Formatting and System Variables . . . . . . . . . . . 184 Change Password . . . . . . . . . . . . . . . . . . . . . . . . . . . . 189 Report Formatting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 190 Headers and Footers . . . . . . . . . . . . . . . . . . . . . . . . . 191 Column Formatting . . . . . . . . . . . . . . . . . . . . . . . . . . 194 BREAK Processing . . . . . . . . . . . . . . . . . . . . . . . . . . 195 Summary Operations (Totals) . . . . . . . . . . . . . . . . . . 196 Substitution Variables . . . . . . . . . . . . . . . . . . . . . . . . . . 198 Saving and Running Scripts . . . . . . . . . . . . . . . . . . . . . . 201 Terms to Know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 204 Review Questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 205 Chapter 10 Creating and Maintaining Database Objects 207 Creating Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 208 Relational Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . . 208 Create Table As Select (CTAS) . . . . . . . . . . . . . . . . . . 209 External Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 211 Temporary Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . 214 Creating Indexes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 215 Creating and Using Views . . . . . . . . . . . . . . . . . . . . . . . 216 User-Defined Views . . . . . . . . . . . . . . . . . . . . . . . . . . 216 Data Dictionary Views . . . . . . . . . . . . . . . . . . . . . . . . 218 Dynamic Performance Views . . . . . . . . . . . . . . . . . . . 222 4372cFM.fm Page viii Monday, August 16, 2004 6:52 PM Contents ix Creating Sequences and Synonyms . . . . . . . . . . . . . . . . . 223 Sequences . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 223 Synonyms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 225 Terms to Know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 226 Review Questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 227 Chapter 11 Users and Security 229 Creating User Accounts . . . . . . . . . . . . . . . . . . . . . . . . . 230 Assigning Passwords . . . . . . . . . . . . . . . . . . . . . . . . . 230 Creating and Assigning Profiles . . . . . . . . . . . . . . . . . 231 Assigning Default Tablespaces and Quotas . . . . . . . . 232 Granting and Revoking Privileges . . . . . . . . . . . . . . . . . 234 System Privileges . . . . . . . . . . . . . . . . . . . . . . . . . . . . 234 Object Privileges . . . . . . . . . . . . . . . . . . . . . . . . . . . . 236 Creating and Assigning Roles . . . . . . . . . . . . . . . . . . 238 Auditing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 240 Statement Auditing . . . . . . . . . . . . . . . . . . . . . . . . . . 240 Object Auditing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 242 Terms to Know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 243 Review Questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 244 Chapter 12 Making Things Run Fast (Enough) 245 Oracle’s Tuning Methodology . . . . . . . . . . . . . . . . . . . . 246 Indexes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 247 When to Create Indexes . . . . . . . . . . . . . . . . . . . . . . 247 Index Types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 247 Creating, Dropping, and Maintaining Indexes . . . . . . 250 Monitoring Indexes . . . . . . . . . . . . . . . . . . . . . . . . . . 252 Data Dictionary Index Information . . . . . . . . . . . . . . 254 Data Design Tuning . . . . . . . . . . . . . . . . . . . . . . . . . . . . 255 Partitioned Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . 255 Materialized Views . . . . . . . . . . . . . . . . . . . . . . . . . . 258 SQL Application Tuning . . . . . . . . . . . . . . . . . . . . . . . . 259 Top SQL Tool . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 260 Explain Plan Graphical Tool . . . . . . . . . . . . . . . . . . . 262 The Oracle Optimizer . . . . . . . . . . . . . . . . . . . . . . . . 264 Memory Tuning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 267 Terms to Know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 270 Review Questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 271 Chapter 13 Saving Your Stuff (Backups) 273 Database Failures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 274 User Backup and Recovery Methods . . . . . . . . . . . . . . . 274 Export and Import for Users . . . . . . . . . . . . . . . . . . . 275 Flashback Query . . . . . . . . . . . . . . . . . . . . . . . . . . . . 280 4372cFM.fm Page ix Monday, August 16, 2004 6:52 PM x Contents DBA Backup and Recovery Methods . . . . . . . . . . . . . . . 282 Export and Import for DBAs . . . . . . . . . . . . . . . . . . . 282 Cold Backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 287 Hot Backups . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 287 Log Miner . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 289 Recovery Manager . . . . . . . . . . . . . . . . . . . . . . . . . . . 290 Terms to Know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 292 Review Questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 293 Chapter 14 Troubleshooting 295 The Alert Log File . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 296 Locating the Alert Log File . . . . . . . . . . . . . . . . . . . . 296 Viewing the Alert Log File . . . . . . . . . . . . . . . . . . . . . 296 Maintaining the Alert Log File . . . . . . . . . . . . . . . . . . 297 Event Notification . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 298 Oracle9 i OEM Event Manager . . . . . . . . . . . . . . . . . 299 Oracle 10 g Advisory Framework . . . . . . . . . . . . . . . . 302 System Trace Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 303 User Trace Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 305 Enabling Tracing . . . . . . . . . . . . . . . . . . . . . . . . . . . . 305 Locating the User Trace Files . . . . . . . . . . . . . . . . . . . 306 Converting the Trace File . . . . . . . . . . . . . . . . . . . . . . 309 Terms to Know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 310 Review Questions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 311 Appendix A Answers to Review Questions 313 Chapter 1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 313 Chapter 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 314 Chapter 3 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 315 Chapter 4 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 316 Chapter 5 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 317 Chapter 6 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 318 Chapter 7 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 319 Chapter 8 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 320 Chapter 9 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 321 Chapter 10 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 322 Chapter 11 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 323 Chapter 12 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 324 Chapter 13 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 325 Chapter 14 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 326 Appendix B Common Database Platforms 327 Enterprise Databases . . . . . . . . . . . . . . . . . . . . . . . . . . . 327 Oracle . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 327 IBM DB2/UDB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 327 4372cFM.fm Page x Monday, August 16, 2004 6:52 PM [...]... database platforms and how they might fit into an enterprise’s database infrastructure About the Author Bob Bryla is an Oracle8 i, Oracle9 i, and Oracle 10g certified professional (OCP) with more than 15 years of database design, database application development, and database administration experience in a variety of fields He is currently an Internet database analyst and DBA at Lands’ End, Inc., in Dodgeville,... make sure that the rows entered into the database tables are accurate and consistent with data in other tables in the database This chapter discusses how you can validate the data before it is inserted into a row of a table Chapter 8, “Installing Oracle and Creating a Database Shows you how to install the database software on the server and create a database using Oracle s GUI-based tools Chapter 9, “Reporting... of relational database technology It defines terms such as tables, rows, and columns, and it provides an introduction to database design Chapter 2, “SQL*Plus and iSQL*Plus Basics” Introduces the various ways to send SQL commands to the database It explains the tools available for issuing SQL commands and how to interact with the database Chapter 3, Oracle Database Functions” Focuses on Oracle functions,... Relational Database Concepts In This Chapter ◆ ◆ ◆ ◆ Every organization has data that needs to be collected, managed, and analyzed A relational database fulfills these needs Along with the powerful features of a relational database come requirements for developing and maintaining the database Data analysts, database designers, and database administrators (DBAs) need to be able to translate the data in a database. .. used—a spreadsheet (also known as the “poor man’s” database) Then you’ll learn about the basic components of a relational database, the data modeling process, and object-relational database features How spreadsheets compare with databases Relational database concepts Data modeling concepts Object-relational database concepts 2 Chapter 1 Are Spreadsheets Like Databases? Most people are familiar with some... coursework What You Need Oracle Database Foundations assumes some minimal level of expertise in using an operating system such as Windows or Unix in a graphical user interface (GUI) environment Any experience with a personal database, such as Microsoft Access, is helpful but not required To follow along with the examples in the book, you will need an installation of the Oracle database software version... hierarchical databases, network databases suffer from rigidity in database structure and high application maintenance costs Hierarchical and network-based databases are still used for extremely high-volume transaction-processing systems IBM claims that 95 percent of the Fortune 1000 companies in the world still use IMS, a hierarchical database management system that is also web-enabled A relational database. .. traditional relational database system and look at how a relational database is designed Once you have a solid understanding of what rows, columns, tables, and relationships are, you’ll be well on your way to leveraging the power of a relational database While this book focuses on the Oracle RDBMS for all of its examples and techniques, it’s good to know how Oracle fits in with other database vendors and... relational database system SQL has been refined and improved by the American National Standards Institute (ANSI) for more than 20 years As of Oracle9 i, Oracle s SQL engine conforms to the ANSI SQL:1999 (also known as SQL3) standard, as well as its own proprietary SQL syntax that existed in previous versions of Oracle Until Oracle9 i, only SQL:1992 (SQL2) syntax was fully supported As of Oracle 10g,... establish yourself in IT So, you want to be an Oracle database administrator (DBA), but you’re not sure what the job might be like? Well, this is a good place to start! This book is intended to bridge the gap for people who are technically oriented and need something to bridge the gap to Oracle database administration If you don’t have a lot of direct experience with databases, this book can get you up to . title Oracle9 i DBA JumpStart © 2003 SYBEX Inc. Library of Congress Card Number: 20041 09313 ISBN: 0-7821-4372-5 SYBEX and the SYBEX logo are either registered trademarks or trademarks of SYBEX. a table. Chapter 8, “Installing Oracle and Creating a Database Shows you how to install the database software on the server and create a database using Oracle s GUI-based tools. Chapter. overview of other database platforms and how they might fit into an enterprise’s database infrastructure. About the Author Bob Bryla is an Oracle8 i , Oracle9 i , and Oracle 10 g