Foreword |
|
xi | |
About the Author |
|
xiv | |
About the Technical Reviewers |
|
xv | |
Acknowledgments |
|
xvi | |
Introduction |
|
xvii | |
Setting Up Your Environment |
|
xxv | |
|
Developing Successful Oracle Applications |
|
|
1 | (48) |
|
|
2 | (2) |
|
|
4 | (5) |
|
How (and How Not) to Develop Database Applications |
|
|
9 | (38) |
|
Understanding Oracle Architecture |
|
|
9 | (6) |
|
Understanding Concurrency Control |
|
|
15 | (5) |
|
|
20 | (6) |
|
|
26 | (16) |
|
``How Do I Make It Run Faster?'' |
|
|
42 | (4) |
|
The DBA--Developer Relationship |
|
|
46 | (1) |
|
|
47 | (2) |
|
|
49 | (16) |
|
Defining Database and Instance |
|
|
50 | (5) |
|
The SGA and Background Processes |
|
|
55 | (2) |
|
|
57 | (5) |
|
|
57 | (2) |
|
|
59 | (1) |
|
Mechanics of Connecting over TCP/IP |
|
|
60 | (2) |
|
|
62 | (3) |
|
|
65 | (50) |
|
|
66 | (12) |
|
|
67 | (2) |
|
Legacy init.ora Parameter Files |
|
|
69 | (2) |
|
Server Parameter Files (SPFILEs) |
|
|
71 | (7) |
|
|
78 | (1) |
|
|
78 | (7) |
|
|
79 | (4) |
|
Trace Files Generated in Response to Internal Errors |
|
|
83 | (2) |
|
|
85 | (1) |
|
|
85 | (3) |
|
|
88 | (8) |
|
A Brief Review of File System Mechanisms |
|
|
89 | (1) |
|
The Storage Hierarchy in an Oracle Database |
|
|
90 | (4) |
|
Dictionary-Managed and Locally-Managed Tablespaces |
|
|
94 | (2) |
|
|
96 | (2) |
|
|
98 | (1) |
|
|
98 | (5) |
|
|
99 | (2) |
|
|
101 | (2) |
|
|
103 | (3) |
|
|
106 | (1) |
|
|
107 | (1) |
|
|
107 | (1) |
|
|
108 | (1) |
|
DMP Files (EXP/IMP Files) |
|
|
108 | (2) |
|
|
110 | (3) |
|
|
113 | (1) |
|
|
114 | (1) |
|
|
115 | (40) |
|
The Process Global Area and User Global Area |
|
|
115 | (20) |
|
Manual PGA Memory Management |
|
|
116 | (7) |
|
Automatic PGA Memory Management |
|
|
123 | (10) |
|
Choosing Between Manual and Auto Memory Management |
|
|
133 | (2) |
|
|
135 | (1) |
|
|
135 | (19) |
|
|
139 | (1) |
|
|
140 | (1) |
|
|
141 | (7) |
|
|
148 | (2) |
|
|
150 | (1) |
|
|
151 | (1) |
|
|
152 | (1) |
|
Automatic SGA Memory Management |
|
|
152 | (2) |
|
|
154 | (1) |
|
|
155 | (28) |
|
|
156 | (14) |
|
Dedicated Server Connections |
|
|
156 | (2) |
|
Shared Server Connections |
|
|
158 | (1) |
|
|
159 | (6) |
|
Dedicated Server vs. Shared Server |
|
|
165 | (4) |
|
Dedicated/Shared Server Wrap-Up |
|
|
169 | (1) |
|
|
170 | (11) |
|
Focused Background Processes |
|
|
171 | (7) |
|
Utility Background Processes |
|
|
178 | (3) |
|
|
181 | (1) |
|
|
181 | (1) |
|
|
182 | (1) |
|
|
182 | (1) |
|
|
183 | (48) |
|
|
183 | (3) |
|
|
186 | (23) |
|
|
186 | (1) |
|
|
187 | (2) |
|
|
189 | (11) |
|
Optimistic or Pessimistic Locking? |
|
|
200 | (1) |
|
|
200 | (3) |
|
|
203 | (5) |
|
|
208 | (1) |
|
|
209 | (21) |
|
|
209 | (8) |
|
|
217 | (3) |
|
|
220 | (9) |
|
Manual Locking and User-Defined Locks |
|
|
229 | (1) |
|
|
230 | (1) |
|
Concurrency and Multi-Versioning |
|
|
231 | (24) |
|
What Are Concurrency Controls? |
|
|
231 | (1) |
|
Transaction Isolation Levels |
|
|
232 | (10) |
|
|
234 | (1) |
|
|
235 | (2) |
|
|
237 | (2) |
|
|
239 | (2) |
|
|
241 | (1) |
|
Implications of Multi-Version Read Consistency |
|
|
242 | (4) |
|
A Common Data Warehousing Technique That Fails |
|
|
242 | (2) |
|
An Explanation for Higher Than Expected I/O on Hot Tables |
|
|
244 | (2) |
|
|
246 | (7) |
|
Consistent Reads and Current Reads |
|
|
247 | (2) |
|
|
249 | (3) |
|
Why Is a Restart Important to Us? |
|
|
252 | (1) |
|
|
253 | (2) |
|
|
255 | (28) |
|
Transaction Control Statements |
|
|
256 | (1) |
|
|
257 | (5) |
|
Statement-Level Atomicity |
|
|
257 | (2) |
|
Procedure-Level Atomicity |
|
|
259 | (3) |
|
Transaction-Level Atomicity |
|
|
262 | (1) |
|
Integrity Constraints and Transactions |
|
|
262 | (3) |
|
|
262 | (1) |
|
Deferrable Constraints and Cascading Updates |
|
|
263 | (2) |
|
|
265 | (8) |
|
|
266 | (6) |
|
|
272 | (1) |
|
|
273 | (2) |
|
|
275 | (6) |
|
How Autonomous Transactions Work |
|
|
275 | (2) |
|
When to Use Autonomous Transactions |
|
|
277 | (4) |
|
|
281 | (2) |
|
|
283 | (54) |
|
|
283 | (1) |
|
|
284 | (3) |
|
How Redo and Undo Work Together |
|
|
287 | (4) |
|
Example Insert-Update-Delete Scenario |
|
|
287 | (4) |
|
Commit and Rollback Processing |
|
|
291 | (9) |
|
|
292 | (6) |
|
|
298 | (2) |
|
|
300 | (23) |
|
|
300 | (2) |
|
Redo Generation and Before/After Triggers |
|
|
302 | (6) |
|
Can I Turn Off Redo Log Generation? |
|
|
308 | (5) |
|
Why Can't I Allocate a New Log? |
|
|
313 | (1) |
|
|
314 | (3) |
|
|
317 | (2) |
|
Temporary Tables and Redo/Undo |
|
|
319 | (4) |
|
|
323 | (13) |
|
What Generates the Most and Least Undo? |
|
|
323 | (2) |
|
ORA-01555: snapshot too old Error |
|
|
325 | (11) |
|
|
336 | (1) |
|
|
337 | (84) |
|
|
337 | (2) |
|
|
339 | (12) |
|
|
339 | (2) |
|
|
341 | (1) |
|
|
342 | (2) |
|
|
344 | (3) |
|
|
347 | (3) |
|
|
350 | (1) |
|
|
351 | (1) |
|
|
351 | (3) |
|
|
354 | (16) |
|
Index Organized Tables Wrap-Up |
|
|
369 | (1) |
|
|
370 | (8) |
|
Index Clustered Tables Wrap-Up |
|
|
378 | (1) |
|
|
378 | (10) |
|
Hash Clustered Tables Wrap-Up |
|
|
387 | (1) |
|
Sorted Hash Clustered Tables |
|
|
388 | (2) |
|
|
390 | (13) |
|
|
391 | (8) |
|
|
399 | (3) |
|
|
402 | (1) |
|
|
403 | (7) |
|
|
410 | (1) |
|
|
410 | (8) |
|
|
418 | (1) |
|
|
418 | (3) |
|
|
421 | (68) |
|
An Overview of Oracle Indexes |
|
|
422 | (1) |
|
|
423 | (25) |
|
|
426 | (3) |
|
|
429 | (6) |
|
|
435 | (2) |
|
When Should You Use a B*Tree Index? |
|
|
437 | (10) |
|
|
447 | (1) |
|
|
448 | (7) |
|
When Should You Use a Bitmap Index? |
|
|
449 | (4) |
|
|
453 | (2) |
|
|
455 | (1) |
|
|
455 | (14) |
|
Important Implementation Details |
|
|
455 | (1) |
|
A Simple Function-Based Index Example |
|
|
456 | (8) |
|
Indexing Only Some of the Rows |
|
|
464 | (2) |
|
Implementing Selective Uniqueness |
|
|
466 | (1) |
|
|
467 | (1) |
|
Caveat Regarding ORA-01743 |
|
|
468 | (1) |
|
Function-Based Indexes Wrap-Up |
|
|
469 | (1) |
|
Application Domain Indexes |
|
|
469 | (2) |
|
Frequently Asked Questions and Myths About Indexes |
|
|
471 | (17) |
|
Do Indexes Work on Views? |
|
|
471 | (1) |
|
Do Nulls and Indexes Work Together? |
|
|
471 | (3) |
|
Should Foreign Keys Be Indexed? |
|
|
474 | (1) |
|
Why Isn't My Index Getting Used? |
|
|
475 | (7) |
|
Myth: Space Is Never Reused in an Index |
|
|
482 | (3) |
|
Myth: Most Discriminating Elements Should Be First |
|
|
485 | (3) |
|
|
488 | (1) |
|
|
489 | (68) |
|
An Overview of Oracle Datatypes |
|
|
489 | (3) |
|
Character and Binary String Types |
|
|
492 | (10) |
|
|
492 | (3) |
|
|
495 | (7) |
|
Binary Strings: RAW Types |
|
|
502 | (2) |
|
|
504 | (9) |
|
Number Type Syntax and Usage |
|
|
507 | (3) |
|
Binary_Float/Binary_Double Type Syntax and Usage |
|
|
510 | (1) |
|
|
511 | (1) |
|
Performance Considerations |
|
|
511 | (2) |
|
|
513 | (7) |
|
Restrictions on Long and Long Raw Types |
|
|
513 | (2) |
|
Coping with Legacy Long Types |
|
|
515 | (5) |
|
Date, Timestamp, and Interval Types |
|
|
520 | (20) |
|
|
521 | (1) |
|
|
522 | (7) |
|
|
529 | (8) |
|
|
537 | (3) |
|
|
540 | (15) |
|
|
541 | (12) |
|
|
553 | (2) |
|
|
555 | (1) |
|
|
556 | (1) |
|
|
557 | (58) |
|
|
558 | (9) |
|
|
558 | (2) |
|
Reduced Administrative Burden |
|
|
560 | (5) |
|
Enhanced Statement Performance |
|
|
565 | (2) |
|
Table Partitioning Schemes |
|
|
567 | (15) |
|
|
567 | (3) |
|
|
570 | (5) |
|
|
575 | (2) |
|
|
577 | (2) |
|
|
579 | (2) |
|
Table Partitioning Schemes Wrap-Up |
|
|
581 | (1) |
|
|
582 | (24) |
|
Local Indexes vs. Global Indexes |
|
|
583 | (1) |
|
|
584 | (6) |
|
|
590 | (16) |
|
Partitioning and Performance, Revisited |
|
|
606 | (6) |
|
Auditing and Segment Space Compression |
|
|
612 | (2) |
|
|
614 | (1) |
|
|
615 | (34) |
|
When to Use Parallel Execution |
|
|
616 | (2) |
|
A Parallel Processing Analogy |
|
|
617 | (1) |
|
|
618 | (6) |
|
|
624 | (3) |
|
|
627 | (12) |
|
Parallel DDL and Data Loading Using External Tables |
|
|
628 | (2) |
|
Parallel DDL and Extent Trimming |
|
|
630 | (9) |
|
|
639 | (1) |
|
|
639 | (9) |
|
Parallel Pipelined Functions |
|
|
640 | (3) |
|
Do-It-Yourself Parallelism |
|
|
643 | (5) |
|
|
648 | (1) |
|
Data Loading and Unloading |
|
|
649 | (56) |
|
|
649 | (31) |
|
Loading Data with SQLLDR FAQs |
|
|
653 | (26) |
|
|
679 | (1) |
|
|
680 | (1) |
|
|
680 | (12) |
|
Setting Up External Tables |
|
|
681 | (6) |
|
|
687 | (3) |
|
Using an External Table to Load Different Files |
|
|
690 | (1) |
|
|
691 | (1) |
|
|
692 | (1) |
|
|
692 | (9) |
|
|
701 | (2) |
|
|
703 | (2) |
Index |
|
705 | |