24
Contents FOREWORD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . XXXIII ACKNOWLEDGMENTS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . XXXV INTRODUCTION . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . XLI PART I Getting Prepared 1 Hardware Considerations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3 Selecting a Vendor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 Support Priority . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 Service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 Compatibility . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5 Upgradability . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6 Performance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7 Availability . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8 Sizing the Web Server and Related Hardware . . . . . . . . . . . . . . . . . . . . 8 Getting Enough Processors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 Getting Enough RAM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12 Getting Enough Storage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13 Choosing an Operating System . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18 Compaq Tru64 UNIX Versus Windows NT on Alpha Processors . 18 ix

Contentsbooks.mhprofessional.com/downloads/products/... · Converting from HTML to PL/SQL . . . . . . . . . . . . . . . . . . . . . . . . 239 ... Building Program Units ... 9 Oracle8i

  • Upload
    lyhanh

  • View
    230

  • Download
    0

Embed Size (px)

Citation preview

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Chapter 1Blind Folio 1:ix

Contents

FOREWORD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . XXXIIIACKNOWLEDGMENTS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . XXXVINTRODUCTION . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . XLI

PART IGetting Prepared

1 Hardware Considerations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3Selecting a Vendor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4

Support Priority . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4Service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5Compatibility . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5Upgradability . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6Performance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7Availability . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8

Sizing the Web Server and Related Hardware . . . . . . . . . . . . . . . . . . . . 8Getting Enough Processors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 9Getting Enough RAM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12Getting Enough Storage . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 13

Choosing an Operating System . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18Compaq Tru64 UNIX Versus Windows NT on Alpha Processors . 18

ix

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:09 PM

Color profile: Generic CMYK printer profileComposite Default screen

Windows NT vs. Linux on Intel Processors . . . . . . . . . . . . . . . . . 18Linux on Non-Intel Processors . . . . . . . . . . . . . . . . . . . . . . . . . . . 21

Researching Available Patches . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22

2 Installation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25Reviewing the System Requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . 27Getting Ready for the Client Requirements . . . . . . . . . . . . . . . . . . . . . . . 28Installing OAS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28Completing the Installation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35

Changing the Node ManagerPassword (or Port) After Installation . . . . . . . . . . . . . . . . . . . . . 36

Correcting the Internal Error . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37Determining How Buggy the Beta Is . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38Correcting ORA-600 Error . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 38Changing the NT

Service Startup Order . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39Loading OAS and the

Database on the Same Machine . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 39Figuring Out if IIS Is a Problem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40Finding Platform-Specific Installation Information . . . . . . . . . . . . . . . . . 40Reviewing the Partner CD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41

WebTrends Log Analyzer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42Symantec Visual Page . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42OpenConnect’s WebConnect . . . . . . . . . . . . . . . . . . . . . . . . . . . 43VitalSign’s Net.Medic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44Eventus’ CONTROL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 44Fujitsu’s COBOL Cartridge . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45

Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45

3 Designing the Site . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47Jump-Starting Your Web Server Knowledge . . . . . . . . . . . . . . . . . . . . . . 48Designing Your Web Team . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49

Internet Executive Steering Committee . . . . . . . . . . . . . . . . . . . . 50Web Master or Commerce Manager . . . . . . . . . . . . . . . . . . . . . . 50Project Manager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 51Web Architect . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 52Content Master . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53Content Manager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53Graphic Designer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53Oracle Database Administrator . . . . . . . . . . . . . . . . . . . . . . . . . . 54IT Operations Administrator . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54

x Oracle8i Web Development

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:x

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:09 PM

Color profile: Generic CMYK printer profileComposite Default screen

Making the Most of the Five C’s . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 54Content . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55Context . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55Cool . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55Contact . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55Control . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56

Planning Your Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56Audience Analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 56Sketching . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57Reality . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57Oneness . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 57Reuse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58Color . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59Layout and Navigation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61Accessibility . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64Simplicity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67Information Rationing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67Avoiding Design Pitfalls . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67

Flowing with Design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70Draw Storyboards . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70Decide on Static, Dynamic, Semidynamic, or Semistatic . . . . . . . 71Review Dynamic Pages in Terms of Code . . . . . . . . . . . . . . . . . . 72Use Designer or Develop the Code by Hand? . . . . . . . . . . . . . . . 72Toolkit – Reusable Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 74Review from Database Standpoint . . . . . . . . . . . . . . . . . . . . . . . . 74Design and Normalize Database . . . . . . . . . . . . . . . . . . . . . . . . . 74

Developing Coding Standards . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75Get vs. Post . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75Using the PL/SQL Toolkit or Not . . . . . . . . . . . . . . . . . . . . . . . . . 76

Understanding How Internet Development Is Different . . . . . . . . . . . . . 77Consider State . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 77Client Functions Using JavaScript . . . . . . . . . . . . . . . . . . . . . . . . 79JavaScript vs. Database Validation . . . . . . . . . . . . . . . . . . . . . . . . 79Controlling Access . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79Dealing with Those Who Will Not Accept Cookies . . . . . . . . . . . 80

Organizing Your Directories . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81Thinking Thin Client . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81

Minimizing Long Load Times . . . . . . . . . . . . . . . . . . . . . . . . . . . 81Maximizing the Image Tag . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82Color Reducing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83Graphics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83Paging Logic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 84

Contents xi

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xi

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:10 PM

Color profile: Generic CMYK printer profileComposite Default screen

xii Oracle8i Web Development

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xii

Archiving Records to Be Accessed Later . . . . . . . . . . . . . . . . . . . 85Drop-Down List Boxes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 86

Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 86

4 OAS Configuration and Tuning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 89Jumping Straight to the Short Tuning Answer . . . . . . . . . . . . . . . . . . . . . 91Analyzing and Tuning Performance . . . . . . . . . . . . . . . . . . . . . . . . . . . . 92

Reviewing Hardware Recommendations . . . . . . . . . . . . . . . . . . . 92Using the OAS Monitor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93Tuning OAS on Solaris . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94Tuning OAS on Windows NT . . . . . . . . . . . . . . . . . . . . . . . . . . . 101Tuning the Process Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101Optimizing FTP Downloads . . . . . . . . . . . . . . . . . . . . . . . . . . . . 102Setting Swap Space and Distributing the Load . . . . . . . . . . . . . . . 102Minimizing the Number of Connections per Client . . . . . . . . . . . 103Tuning Database Access . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 104Tuning the Logging Service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107

Administering OAS Processes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 108Managing Listeners . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 111

Stopping and Starting Listeners . . . . . . . . . . . . . . . . . . . . . . . . . . 111Understanding Ports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 111Web Listener Configuration Tips . . . . . . . . . . . . . . . . . . . . . . . . . 112Listener Performance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114Administering Your HTTP Listeners . . . . . . . . . . . . . . . . . . . . . . . 114Monitoring Your HTTP Listeners . . . . . . . . . . . . . . . . . . . . . . . . . 114Adding a New Listener . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 117Configuring a Listener . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 121Configuring Server Parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . 126Tuning Listeners . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 134

Configuring Applications and Cartridges . . . . . . . . . . . . . . . . . . . . . . . . 137Applications and Cartridge Servers . . . . . . . . . . . . . . . . . . . . . . . 138Application and Cartridge Life Cycle . . . . . . . . . . . . . . . . . . . . . . 138Configuring Cartridges . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 140Tuning and Managing Cartridges . . . . . . . . . . . . . . . . . . . . . . . . . 149Configuring Applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 154Modifying Applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 165

Managing and Configuring Database Access Descriptors (DADs) . . . . . . 170Administering Your DADs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 170Adding a DAD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 171

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:10 PM

Color profile: Generic CMYK printer profileComposite Default screen

Contents xiii

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xiii

Adding Nodes and Processes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 175Adding a New Node . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 177Adding a New Process . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 178

Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 180

5 WebDB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 183Considering Why You Should Use WebDB . . . . . . . . . . . . . . . . . . . . . . 186Looking at Primary Functionality . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186Installing WebDB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 186Using the Navigation Toolbar . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 190Helping Yourself . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 191

Reviewing Some Frequently Asked Questions . . . . . . . . . . . . . . . 192Browsing the Database . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 194Building Objects and Components . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 199

Utilities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 200Finding Components . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 202Building WebDB Components . . . . . . . . . . . . . . . . . . . . . . . . . . 204Building Forms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 205Building Reports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 211Building Charts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 212Building Menus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 212Building Frame Drivers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 212Building Dynamic Pages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 212Building Calendars . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213Building Hierarchies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213Building Shared Components . . . . . . . . . . . . . . . . . . . . . . . . . . . 214Building Oracle Database Objects . . . . . . . . . . . . . . . . . . . . . . . 218

Administering WebDB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 219Making the Most of the User Manager . . . . . . . . . . . . . . . . . . . . . 219Using the Grant Manager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 220Using the Role Manager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 220Changing Your Password . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 220Reporting Privileges . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 220Configuring Activity Log . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 220Setting Listener and Database Access Descriptor (DAD)

Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 220Monitoring Your Objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 220

Monitoring User Interface Component Performance . . . . . . . . . . 221Reviewing the Activity Log . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 222Monitoring Database Objects . . . . . . . . . . . . . . . . . . . . . . . . . . . 223Reviewing Batch Job Results and Performance . . . . . . . . . . . . . . 223

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:11 PM

Color profile: Generic CMYK printer profileComposite Default screen

xiv Oracle8i Web Development

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xiv

Building Sites . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 223Administering Your Site . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 224

Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 232

6 Oracle Extras . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 235Establishing a Web Development Toolkit . . . . . . . . . . . . . . . . . . . . . . . . 236

Jump-Starting Your Applications . . . . . . . . . . . . . . . . . . . . . . . . . 237Finding Cool Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 238Creating Your Toolkit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 238Finding and Using Oracle Freebies . . . . . . . . . . . . . . . . . . . . . . . 238

Using WebAlchemy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 239Converting from HTML to PL/SQL . . . . . . . . . . . . . . . . . . . . . . . . 239Using Positional Versus Named Notation . . . . . . . . . . . . . . . . . . 239

Generating Graphs Using OWA_CHART . . . . . . . . . . . . . . . . . . . . . . . . 240Using Oracle’s Java Plug-In - JInitiator . . . . . . . . . . . . . . . . . . . . . . . . . . 242Using the Web Publishing Assistant . . . . . . . . . . . . . . . . . . . . . . . . . . . . 243

Creating a New Web Page . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 243Logging into a Database . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 244Building Your Query . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 244Scheduling Your Query . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 245Defining File Options and Picking a Template . . . . . . . . . . . . . . . 247Understanding the Web Publishing

Assistant Template Language . . . . . . . . . . . . . . . . . . . . . . . . . 248Configuring SQL*Net . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 253

Understanding SQL*Net Parameters . . . . . . . . . . . . . . . . . . . . . . 253Establishing Your SQL*Net Parameters . . . . . . . . . . . . . . . . . . . . 256

Configuring and Using SQL*Plus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 256Modifying SQL*Plus Configure Files . . . . . . . . . . . . . . . . . . . . . . 256

SQL*Loader . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 257Making the Most of

Oracle File Packager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 259Using the Oracle File Packager . . . . . . . . . . . . . . . . . . . . . . . . . . 259

Using Oracle’s Enterprise Manager . . . . . . . . . . . . . . . . . . . . . . . . . . . . 260Instance Manager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 260Schema Manager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 260Security Manager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 261SQL Worksheet . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 261Software Manager . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 261

Using Oracle’s GUI PL/SQL Editor – Procedure Builder . . . . . . . . . . . . . 261Building Program Units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 262Debugging Program Units . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 262Building a Library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 263

Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 263

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:11 PM

Color profile: Generic CMYK printer profileComposite Default screen

Contents xv

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xv

7 24x7 Uptime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 267Oracle Parallel Server . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 272

Advantages of OPS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 272Disadvantages of OPS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 274Automatic Failure Recovery Under OPS . . . . . . . . . . . . . . . . . . . 275

Advanced Replication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 276Advantages of Advanced Replication . . . . . . . . . . . . . . . . . . . . . 278Disadvantages of Advanced Replication . . . . . . . . . . . . . . . . . . . 278Automatic Failure Recovery with Advanced Replication . . . . . . . 279

Standby Instances . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 279Advantages of Standby Instances . . . . . . . . . . . . . . . . . . . . . . . . . 281Disadvantages of Standby Instances . . . . . . . . . . . . . . . . . . . . . . 281Automatic Failure Recovery with Standby Instances . . . . . . . . . . 282

Standby Databases . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 282Advantages of Standby Databases . . . . . . . . . . . . . . . . . . . . . . . . 286Disadvantages of Standby Databases . . . . . . . . . . . . . . . . . . . . . . 286Automatic Failure Recovery with Standby Databases . . . . . . . . . 287

Third-Party Solutions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 288Combining Multiple Solutions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 288Custom Standby Database Strategies . . . . . . . . . . . . . . . . . . . . . . . . . . . 289End-User Session Disruption and Application Failover . . . . . . . . . . . . . . 289Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 290References . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 290

8 HTTP Listeners . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 293Using the Oracle Listener . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 295Configuring IIS, Netscape FastTrack, Netscape Enterprise, or the Apache

Listener with OAS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 297Undoing the Registration of IIS, Netscape FastTrack, Netscape

Enterprise, or the Apache Listener from OAS . . . . . . . . . . . . . . 298Comparing IIS Speed with

Oracle (Spyglass) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 299Turning File Caching Off . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 299Tuning Your TCP/IP Parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 300Guarding Your Base Domain Name . . . . . . . . . . . . . . . . . . . . . . . . . . . . 301Monitoring Open Connections . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 301Monitoring Your Site for Crashes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 304Starting and Stopping OAS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 306Setting the Rescan Interval . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 307Analyzing Why the Listener Does Not Notice that File Permissions

Have Changed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 308Troubleshooting Why You Cannot Access the Node Manager . . . . . . . . 308

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:11 PM

Color profile: Generic CMYK printer profileComposite Default screen

Copying a Listener from Another Server . . . . . . . . . . . . . . . . . . . . . . . . . 309Configuring the Listener to Run on Port 80 on a UNIX Machine . . . . . . . 309Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 309

9 Oracle8i Built-In Packages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 311Messaging with dbms_alert . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 312

register . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 314remove . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 315removeall . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 315waitany . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 315waitone . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 316signal . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 316

Setting SGA Variables with dbms_application_info . . . . . . . . . . . . . . . . 317set_module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 317set_action . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 318read_module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 318set_client_info . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 318read_client_info . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 319set_session_longops . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 319

Executing DDL with dbms_ddl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 320alter_compile . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 320analyze_object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 321alter_table_referenceable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 321

Queuing with dbms_ job . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 322Accessing Objects with dbms_lob . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 325Writing Output with dbms_output . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 326

enable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 327disable . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 327put . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 328put_line . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 328new_line . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 328get_line . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 328get_lines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 329

Messaging with dbms_pipe . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 329pack_message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 332unpack_message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 332next_item_type . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 333create_pipe . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 333remove_pipe . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 334send_message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 334receive_message . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 335reset_buffer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 335

xvi Oracle8i Web Development

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xvi

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:12 PM

Color profile: Generic CMYK printer profileComposite Default screen

Contents xvii

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xvii

purge . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 335unique_session_name . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 336

Setting Session Properties with dbms_session . . . . . . . . . . . . . . . . . . . . . 336set_role . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 336set_sql_trace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 336set_nls . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 336close_database_link . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 337reset_package . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 337unique_session_id . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 337is_role_enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 337is_session_alive . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 338set_close_cached_open_cursors . . . . . . . . . . . . . . . . . . . . . . . . . 338free_unused_user_memory . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 338

Executing Dynamic SQL Using dbms_sql . . . . . . . . . . . . . . . . . . . . . . . . 339open_cursor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 340is_open . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 340close_cursor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 340parse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 340bind_variable, bind_variable_char, bind_variable_raw,

bind_variable_rowid, bind_array . . . . . . . . . . . . . . . . . . . . . . 341define_column, define_column_char, define_column_raw,

define_column_rowid, and define_array . . . . . . . . . . . . . . . . . 344execute . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 346fetch_rows . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 346execute_and_fetch . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 346column_value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 347variable_value, variable_value_char, variable_value_raw,

variable_value_rowid . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 348last_error_position, last_sql_function_code, last_row_count,

and last_row_id . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 349Setting the Trace Level with dbms_trace . . . . . . . . . . . . . . . . . . . . . . . . . 350

set_plsql_trace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 350clear_plsql_trace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 350plsql_trace_version . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 350

Making the Most of dbms_utility . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 351compile_schema . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 351analyze_schema . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 351analyze_database . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 352format_error_stack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 352format_call_stack . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 352is_parallel_server . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 352

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:12 PM

Color profile: Generic CMYK printer profileComposite Default screen

xviii Oracle8i Web Development

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xviii

get_time . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 352get_parameter_value . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 354name_resolve . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 354name_tokenize . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 355comma_to_table . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 356table_to_comma . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 356port_string . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 356db_version . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 356analyze_part_object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 357exec_ddl_statement . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 357current_instance . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 358active_instances . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 358

Accessing Operating System Files with utl_file . . . . . . . . . . . . . . . . . . . . 358fopen, Version 1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 360fopen, Version 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 360is_open . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 360fclose . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 361fclose_all . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 361get_line . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 361put . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 361new_line . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 362put_line . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 362putf . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 362fflush . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 362

Maximizing utl_http . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 363request . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 367request_pieces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 368

Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 369

PART IICore Concepts

10 Differences Among the Various Oracle Web Server Versions . . . . . . . . . . . . 373Taking a Look at What’s New in OAS 4.0 . . . . . . . . . . . . . . . . . . . . . . . 376New Features in Administration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 376

Climbing Down the OAS Manager Navigational Tree . . . . . . . . . 378Understanding the OAS Manager Operational Buttons . . . . . . . . 380Climbing the OAS Utilities Navigational Tree . . . . . . . . . . . . . . . 381Reviewing the OAS Command-Line Utilities . . . . . . . . . . . . . . . . 384Accessing the Online Documentation . . . . . . . . . . . . . . . . . . . . . 384

Enhancements in OAS Architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . 385Understanding that Applications Now Contain Cartridges . . . . . . 388

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:13 PM

Color profile: Generic CMYK printer profileComposite Default screen

Contents xix

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xix

Tuning the Cartridge Server, Which Can Run MultithreadedCartridges . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 388

Understanding OAS Transactions . . . . . . . . . . . . . . . . . . . . . . . . 390Balancing the Load . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 391Being Ready with Failure Recovery . . . . . . . . . . . . . . . . . . . . . . . 392Clamping Down on Security . . . . . . . . . . . . . . . . . . . . . . . . . . . . 393

Advancements in Cartridges . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 394Installing the PL/SQL Cartridge Web Toolkit . . . . . . . . . . . . . . . . 395Comparing Applications to PL/SQL Agents . . . . . . . . . . . . . . . . . 396Using Flexible Parameter Passing . . . . . . . . . . . . . . . . . . . . . . . . 397Using Positional Parameter Passing . . . . . . . . . . . . . . . . . . . . . . . 398Executing PL/SQL Source Files from Script . . . . . . . . . . . . . . . . . 399Implementing Your Own Custom Authentication . . . . . . . . . . . . 403Uploading and Downloading Files to and from the Database . . . 411Understanding OWA_CONTENT in Detail . . . . . . . . . . . . . . . . . 414Understanding the Content Helper (OWS_CS) . . . . . . . . . . . . . . . 419Using the New OWA_UTIL.MIME_HEADER Parameter . . . . . . . 419Using the New OWA_UTIL.CELLSPRINT Parameter . . . . . . . . . . 420Decommissioning of the OWA_INIT Package . . . . . . . . . . . . . . . 420Thinking About the Perl Cartridge Enhancements . . . . . . . . . . . . 420Considering LiveHTML Cartridge Is Now Real . . . . . . . . . . . . . . . 420Looking at the Java Cartridges . . . . . . . . . . . . . . . . . . . . . . . . . . . 420

Working with OAS 4.0 and Other Oracle Products . . . . . . . . . . . . . . . . 423Looking at the Oracle Enterprise Developer Suite . . . . . . . . . . . . 423Thinking About the Oracle JDeveloper Suite . . . . . . . . . . . . . . . . 423Using Oracle Developer Server . . . . . . . . . . . . . . . . . . . . . . . . . . 423Combining Oracle Applications with OAS . . . . . . . . . . . . . . . . . 424Using Oracle Enterprise Manager . . . . . . . . . . . . . . . . . . . . . . . . 424Implementing Oracle Internet Commerce Server . . . . . . . . . . . . . 424Using Oracle Payment Server . . . . . . . . . . . . . . . . . . . . . . . . . . . 424Purchasing Oracle Data Mart Suite . . . . . . . . . . . . . . . . . . . . . . . 424Using Oracle Express OLAP Server . . . . . . . . . . . . . . . . . . . . . . . 424Reviewing Oracle Discoverer . . . . . . . . . . . . . . . . . . . . . . . . . . . 424Implementing Oracle Video Server . . . . . . . . . . . . . . . . . . . . . . . 425

Comparing OAS 4.0 to OAS 4.0 Enterprise Edition . . . . . . . . . . . . . . . . . 425Third-Party Tools Bundled with OAS . . . . . . . . . . . . . . . . . . . . . . . . . . . 426Reviewing OAS 4.0 Requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 426Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 429

11 HTML Development . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 431Writing HTML . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 433

Working with the Browsers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 434<NOSCRIPT> . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 435

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:13 PM

Color profile: Generic CMYK printer profileComposite Default screen

xx Oracle8i Web Development

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xx

<NOFRAMES> . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 436<NOEMBED> . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 437<NOLAYER> . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 437

Viewing the HTML Source Without the Results . . . . . . . . . . . . . . . . . . . 438Refreshing a Web Page After a Given Interval . . . . . . . . . . . . . . . . . . . . 438Using HTML Tables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 439Adding Images in a Table . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 440Creating an HTML Form . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 441

Limiting Data That Can Be Entered . . . . . . . . . . . . . . . . . . . . . . . 443Creating Images That Act Like Buttons . . . . . . . . . . . . . . . . . . . . . 445Working with URLs and Hyperlinks . . . . . . . . . . . . . . . . . . . . . . 448

Forcing Side-by-Side Forms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 453Suppressing the Return Key in IE . . . . . . . . . . . . . . . . . . . . . . . . . 454

Implementing Cascading Style Sheets—Advantages and Disadvantages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 454

Creating Subject and/or Text for Email . . . . . . . . . . . . . . . . . . . . . . . . . . . 456Sending Email from an HTML Form . . . . . . . . . . . . . . . . . . . . . . . . . . . . 456Indenting Your Text . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 457Placing Two Headings on the Same Line . . . . . . . . . . . . . . . . . . . . . . . . 457Creating the TV Look . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 458Clearing All Frames . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 458Referencing CGI Scripts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 459Adding a Page Counter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 460Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 461

12 JavaScript Development . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 463Comparing JavaScript to PL/SQL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 466

Using Semicolons or Not . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 466Defining Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 467Reviewing the JavaScript Keywords and Reserved Words . . . . . . 467Looking at JavaScript Literals . . . . . . . . . . . . . . . . . . . . . . . . . . . . 467Separating and Beautifying Your Code . . . . . . . . . . . . . . . . . . . . 467Commenting JavaScript . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 467Understanding JavaScript Operators . . . . . . . . . . . . . . . . . . . . . . 468Controlling Your Structures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 468Modeling the Objects or Object Modeling? . . . . . . . . . . . . . . . . . 469

The Intricacies of OAS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 472Handling Browser Incompatibilities . . . . . . . . . . . . . . . . . . . . . . . . . . . . 472Writing Browser-Specific Code from PL/SQL . . . . . . . . . . . . . . . . . . . . . 474Reusing Your JavaScript Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 476

Mocking WebDB’s JavaScriptLibrary Functionality . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 476

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:13 PM

Color profile: Generic CMYK printer profileComposite Default screen

Contents xxi

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xxi

Writing a PL/SQL JavaScript Library Package . . . . . . . . . . . . . . . . 476Using a JavaScript Library Instead of Inline JavaScript . . . . . . . . . 477Referencing a Static JavaScript Library . . . . . . . . . . . . . . . . . . . . . 478

Programming User-DefinedAlert Processing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 478

Displaying Properties on the Screen . . . . . . . . . . . . . . . . . . . . . . . . . . . . 479Opening a New Window Passing Parameters . . . . . . . . . . . . . . . . . . . . . 485Assigning JavaScript Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 485Using the Submit Button . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 487Validating Form Fields . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 488Handling Exceptions with the onError Event Handler . . . . . . . . . . . . . . . 489Working with PL/SQL Code and Various Browsers . . . . . . . . . . . . . . . . . 491Making a Two-Dimensional Array in JavaScript . . . . . . . . . . . . . . . . . . . 491Assigning JavaScript Variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 492Invoking a PL/SQL Procedure from a Pick List . . . . . . . . . . . . . . . . . . . . 493Changing Frames Simultaneously . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 493Resolving the Access Denied Error . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 494Building JavaScript Menus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 494Passing Spaces as a Part of the URL . . . . . . . . . . . . . . . . . . . . . . . . . . . . 495Debugging onFocus with Alert Will Not Work . . . . . . . . . . . . . . . . . . . . 495Subscribing to the JavaScript OnFocus Newsletter . . . . . . . . . . . . . . . . . 496Reviewing Visual JavaScript Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 496

Talking About NetObjects ScriptBuilder . . . . . . . . . . . . . . . . . . . 497Taking a Quick Look at Netscape’s Visual JavaScript . . . . . . . . . . 497

Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 497

13 XML . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 499Understanding the Basic Rules of XML . . . . . . . . . . . . . . . . . . . . . . . . . . 501

Defining Document Type Declarations (DTD) . . . . . . . . . . . . . . . 501Defining Well-Formed . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 501Defining Validity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 502

Examining XML Document Syntax and Structure . . . . . . . . . . . . . . . . . . 502Looking at Case . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 503Examining Element Type Declarations in the DTD . . . . . . . . . . . 503Examining Attribute-List Declarations in the DTD . . . . . . . . . . . . 504

Examining Common XML Document APIs . . . . . . . . . . . . . . . . . . . . . . . 506Looking at the Document Object Model (DOM) . . . . . . . . . . . . . 506Looking at SAX (Simple API for XML) . . . . . . . . . . . . . . . . . . . . . 507

Comparing XML and HTML . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 508Looking at Common Ancestry . . . . . . . . . . . . . . . . . . . . . . . . . . . 509Looking at Differences in Syntax and Structure . . . . . . . . . . . . . . 509

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:14 PM

Color profile: Generic CMYK printer profileComposite Default screen

Creating a Sample XML Document . . . . . . . . . . . . . . . . . . . . . . . . . . . . 509Creating the Suspect DTD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 510Creating the Document . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 511

Using XSL to Format and Display XML Documents . . . . . . . . . . . . . . . . 512Defining XSL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 512Using XSL to Display XML Data as HTML . . . . . . . . . . . . . . . . . . 513

XML Support in Oracle8i . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 516Examining XML and Oracle ConText . . . . . . . . . . . . . . . . . . . . . . . . . . . 516Examining the Oracle XML Parser . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 517

Installing the Oracle XML Parser . . . . . . . . . . . . . . . . . . . . . . . . . 518Running the Oracle XML Parser Outside of the Database . . . . . . 518Running the Oracle XML Parser Inside of the Database . . . . . . . . 528Obtaining the Oracle XML Parser Utility . . . . . . . . . . . . . . . . . . . 532

Examining the Oracle XML Class Generator . . . . . . . . . . . . . . . . . . . . . . 532Implementing the Oracle XML Class Generator . . . . . . . . . . . . . . 532Obtaining the Oracle XML Class Generator . . . . . . . . . . . . . . . . . 539

Examining the Oracle XML SQL Utility . . . . . . . . . . . . . . . . . . . . . . . . . 539Defining the OracleXML Class . . . . . . . . . . . . . . . . . . . . . . . . . . 540Defining the OracleXMLStore Class . . . . . . . . . . . . . . . . . . . . . . . 541Defining the OracleXMLQuery Class . . . . . . . . . . . . . . . . . . . . . . 541Defining the OracleXMLSave Class . . . . . . . . . . . . . . . . . . . . . . . 541Defining the xmlgen PL/SQL Package . . . . . . . . . . . . . . . . . . . . . 541Obtaining the Oracle XML SQL Utility . . . . . . . . . . . . . . . . . . . . 544

Examining the Oracle XSQL Servlet . . . . . . . . . . . . . . . . . . . . . . . . . . . . 544Examining Oracle XSQL Servlet Dependencies and

Requirements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 544Generating a Dynamic XML Document . . . . . . . . . . . . . . . . . . . . 545Obtaining the Oracle XSQL Servlet . . . . . . . . . . . . . . . . . . . . . . . 545

Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 546

14 PL/SQL Cartridge . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 549Going from PL/SQL and HTML to Web Development . . . . . . . . . . . . . . 552

Understanding the PL/SQL Web Toolkit . . . . . . . . . . . . . . . . . . . 552Using Your HTML Knowledge . . . . . . . . . . . . . . . . . . . . . . . . . . . 555Using WebAlchemy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 556Performing Magic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 556Adding Your PL/SQL Logic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 557Calling Your Web Procedure . . . . . . . . . . . . . . . . . . . . . . . . . . . . 559

Passing Parameters to Your PL/SQL Procedures . . . . . . . . . . . . . . . . . . . 560Retrieving CGI Environment Variables . . . . . . . . . . . . . . . . . . . . . . . . . . 563Maintaining Source Code History . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 565Storing Cookies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 566

xxii Oracle8i Web Development

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xxii

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:14 PM

Color profile: Generic CMYK printer profileComposite Default screen

Referring to Pseudocolumns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 566Calculating Time to the Hundredth of a Second . . . . . . . . . . . . . . . . . . . 567Making External Calls from PL/SQL . . . . . . . . . . . . . . . . . . . . . . . . . . . . 567Wrapping or Securing Your Procedures from Source Viewing . . . . . . . . 568Redirecting Users to Another URL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 569Sending Mail Using UTL_FILE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 571Extracting and Viewing a BLOB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 573Querying Multiple Selects from Listbox . . . . . . . . . . . . . . . . . . . . . . . . . 574Wrapping Text Without Using <PRE> . . . . . . . . . . . . . . . . . . . . . . . . . . 576Generating a PDF Report from PL/SQL . . . . . . . . . . . . . . . . . . . . . . . . . . 577Clearing the Buffer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 577Improving PL/SQL Error Messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 577New ROWID Format . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 578Debugging PL/SQL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 579Disappearing Sessions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 580Encrypting Key Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 580Ordering Data Based on User Requests . . . . . . . . . . . . . . . . . . . . . . . . . 581Editing PL/SQL Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 583Receiving an Authorization Check Failure After Upgrading . . . . . . . . . . 583Catching the Domain Name from an IP . . . . . . . . . . . . . . . . . . . . . . . . . 584Missing Radio Buttons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 584Submitting a Form, the Hard Way . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 585Overdefining Actions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 586Converting Numbers to Words—Literally . . . . . . . . . . . . . . . . . . . . . . . . 586Enhancing Client Sessions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 587Using Transaction Services . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 589Getting Information About Your Users . . . . . . . . . . . . . . . . . . . . . . . . . . 590PL/SQL XML Utilities . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 596Understanding Why htp.linkrel Is Now Useful . . . . . . . . . . . . . . . . . . . . 598OAS PL/SQL 4.0 Web Toolkit Additions . . . . . . . . . . . . . . . . . . . . . . . . . 598Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 599

15 Security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 601OAS Built-In Security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 603

Setting Up Security for a Virtual Path . . . . . . . . . . . . . . . . . . . . . . 603Configuring Authentication Services . . . . . . . . . . . . . . . . . . . . . . 603Comparing In-Memory to ORB Communication . . . . . . . . . . . . . 611

Application-Level Security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 611Requesting Authentication upon Each Request . . . . . . . . . . . . . . 612Passing Authentication Along . . . . . . . . . . . . . . . . . . . . . . . . . . . 612Combining Database Authentication . . . . . . . . . . . . . . . . . . . . . . 613Combining Basic or Digest Authentication . . . . . . . . . . . . . . . . . 613

Contents xxiii

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xxiii

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:15 PM

Color profile: Generic CMYK printer profileComposite Default screen

xxiv Oracle8i Web Development

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xxiv

Using owa_custom . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 613Baking Cookies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 613

Network Security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 649Basics of SSL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 649Setting Up SSL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 650Tips for Setting Up SSL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 650Protecting Digital Certificates . . . . . . . . . . . . . . . . . . . . . . . . . . . 652Securing Email with Digital IDs . . . . . . . . . . . . . . . . . . . . . . . . . . 652Securing Credit Card Transactions . . . . . . . . . . . . . . . . . . . . . . . . 652

RDBMS Security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 653Encrypting with PL/SQL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 653PL/SQL Interface to Oracle Cryptographic Toolkit . . . . . . . . . . . . 653Setting Up a Secure Schema Plan . . . . . . . . . . . . . . . . . . . . . . . . 654

Physical Security . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 655Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 655

PART IIIOracle Tools

16 Using Designer to Develop Web Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 659Understanding the Packages Generated by Designer . . . . . . . . . . . . . . . 662

Understanding Module Package Procedures . . . . . . . . . . . . . . . . 662Understanding How Named Routines Are Handled . . . . . . . . . . 665Understanding How Events Are Handled . . . . . . . . . . . . . . . . . . 666Understanding How User Text Is Handled . . . . . . . . . . . . . . . . . 666Understanding Procedure Parameters . . . . . . . . . . . . . . . . . . . . . 666Understanding the Package-Defined Record Types . . . . . . . . . . . 667

Incorporating Views into Generated Modules . . . . . . . . . . . . . . . . . . . . 668Building an Effective Database Security Scheme

when Using Generated Modules . . . . . . . . . . . . . . . . . . . . . . . . . . . . 669Using Events and Named Routines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 670

Using Named Routines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 670Using Events . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 671

Leveraging Key Web Server Generator Preferences and Attributes . . . . . 672Using HTML Tags in Module Components . . . . . . . . . . . . . . . . . 673Registering and Using External PL/SQL Packages in User Text . . . 673Setting the Module Layout Style . . . . . . . . . . . . . . . . . . . . . . . . . 674

Using Frames and Style Sheets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 675Using Style Sheets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 676Including a Style Sheet Using the <STYLE> Tag . . . . . . . . . . . . . . 682Referencing External Style Sheets . . . . . . . . . . . . . . . . . . . . . . . . 683

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:15 PM

Color profile: Generic CMYK printer profileComposite Default screen

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xxv

Using Unbound Items . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 685Leveraging the User Text Area . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 685

Formatting Text with PL/SQL Functions . . . . . . . . . . . . . . . . . . . . 686Formatting Text with HTML . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 687Adding HTML Syntax to User Text . . . . . . . . . . . . . . . . . . . . . . . 687Adding Entire HTML Documents via an HTML Editor . . . . . . . . . 688

Using JavaScript . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 690Avoiding the Proprietary Pitfall . . . . . . . . . . . . . . . . . . . . . . . . . . 690Using External JavaScript Libraries . . . . . . . . . . . . . . . . . . . . . . . . 691Creating Oracle Server-Side JavaScript Libraries . . . . . . . . . . . . . 691Understanding Web Server Generator Naming Conventions . . . . 693Naming Convention for Event Handlers . . . . . . . . . . . . . . . . . . . 693Understanding the ctl Parameter . . . . . . . . . . . . . . . . . . . . . . . . . 693

Overriding Designer’s Default Functionality . . . . . . . . . . . . . . . . . . . . . . 693Using Arguments . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 695Navigating Between Modules Using Cookies and PL/SQL . . . . . . . . . . . 696

Creating Custom Hyperlinks with PL/SQL and HTML . . . . . . . . . 696Creating Dynamic Hyperlinks Between Modules

Using Cookies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 696Defining Cookies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 697Creating a Cookie . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 697Reading a Cookie . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 697Using Cookies to Create Links . . . . . . . . . . . . . . . . . . . . . . . . . . . 698Limitations of Multiple Cookies . . . . . . . . . . . . . . . . . . . . . . . . . . 699Overcoming the 20-Cookie Limit with

Logical Cookies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 699Applying Logical Cookies to a Web Server

Generator Module . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 705Discussing Lists of Values (LOVs) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 705

Looking at Web Server Generator’s Flavor of LOV . . . . . . . . . . . 706Creating a Custom LOV Using Oracle8 Objects . . . . . . . . . . . . . 707Coding the LOV Object . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 708Implementing the LOV Object . . . . . . . . . . . . . . . . . . . . . . . . . . 724

Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 727

17 Oracle Developer - Forms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 729Deciding to Use Oracle Forms (Or Not) . . . . . . . . . . . . . . . . . . . . . . . . . 731

How It Works . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 731State, Licensing, and Memory . . . . . . . . . . . . . . . . . . . . . . . . . . . 732Existing Forms? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 732Browser and Bandwidth . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 733Decision Time . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 733

Contents xxv

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:15 PM

Color profile: Generic CMYK printer profileComposite Default screen

xxvi Oracle8i Web Development

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xxvi

Installing Oracle Forms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 734Creating the Virtual Directories . . . . . . . . . . . . . . . . . . . . . . . . . . 734

Making Sure Your Icons Appear on the Web . . . . . . . . . . . . . . . . . . . . . 735Configuring Oracle Forms as a CGI (Noncartridge) . . . . . . . . . . . . . . . . 736

Noncartridge (CGI) URL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 737Configuring Oracle Forms 6.0 as a Cartridge . . . . . . . . . . . . . . . . . . . . . 738Configuring Oracle Forms 5.0 as a Cartridge . . . . . . . . . . . . . . . . . . . . . 740Creating the Generic Cartridge HTML File . . . . . . . . . . . . . . . . . . . . . . . 743Understanding the Cartridge URL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 746Using a Non-Oracle Web Server . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 747Generating and Placing Your FMX Files . . . . . . . . . . . . . . . . . . . . . . . . . 747Setting Up Forms Server as Windows NT Service . . . . . . . . . . . . . . . . . . 748Starting and Stopping the Forms Server Listener . . . . . . . . . . . . . . . . . . . 748Configuring the Forms Client . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 749Setting Up Load Balancing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 749Designing Web Applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 750

Reducing Network Traffic . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 750Selecting Fonts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 751

Memory Requirements Too High for Comfort? . . . . . . . . . . . . . . . . . . . . 751Understanding Feature Restrictions for Forms on the Web . . . . . . . . . . . 752Finding Good Papers on Web-Enabled Forms . . . . . . . . . . . . . . . . . . . . 753Analyzing sysdate Issues with Oracle8 and Forms 5.0 PL/SQL . . . . . . . . 753Resolving FRM-40735 Messages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 755Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 755

18 Oracle Developer – Reports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 757Deploying Reports on the Web . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 759Setting Up the Reports Server – General Information . . . . . . . . . . . . . . . 760

Setting Up Reports on OAS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 760Configuring Oracle Reports as a CGI . . . . . . . . . . . . . . . . . . . . . . . . . . . 767

Setting Up Reports as a CGI Under NT . . . . . . . . . . . . . . . . . . . . 767Setting Up Reports as a CGI Under UNIX . . . . . . . . . . . . . . . . . . 767

Configuring Oracle Reports 6.0 as a Cartridge . . . . . . . . . . . . . . . . . . . . 768Configuring Oracle Reports 3.0 as a Cartridge . . . . . . . . . . . . . . . . . . . . 769Setting Optional Reports Parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . 771Specifying URL Run Requests for Reports . . . . . . . . . . . . . . . . . . . . . . . . 775Adding Web Functionality . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 776

Hyperlinks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 777Creating Bookmarks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 779

Prompting for the Parameter Form . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 780Configuring the Default Printer for Oracle Reports on UNIX . . . . . . . . . 781Identifying Reports Server Errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 782Running Multiple Reports Concurrently . . . . . . . . . . . . . . . . . . . . . . . . . . 782

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:16 PM

Color profile: Generic CMYK printer profileComposite Default screen

Contents xxvii

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xxvii

Using MetaLink to Figure Out Why RUN_PRODUCT Fails . . . . . . . . . . 783Creating Headers, Footers, and Page Breaks for Web Pages . . . . . . . . . . 784Resolving the PDF Issue in IE (and AOL) . . . . . . . . . . . . . . . . . . . . . . . . 784Suggesting Oracle Reports Performance Tips . . . . . . . . . . . . . . . . . . . . . 791

SRW.DO_SQL Statements . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 792Using CDE_MM.GET_REF . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 792When You Should Use Multiquery Data Models . . . . . . . . . . . . . 792Indexes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 793Modifications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 793Break Columns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 794Maximum Rows and Group Filters . . . . . . . . . . . . . . . . . . . . . . . 794Unused Data Model Objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . 795Unused Frames . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 795Total Number of Pages . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 795Format Triggers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 795Oracle Graphics Integration . . . . . . . . . . . . . . . . . . . . . . . . . . . . 795

Developing Data to Generate Acrobat PDF Files . . . . . . . . . . . . . . . . . . 796Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 796

PART IVOther Cartridge Options

19 Java and OAS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 799Understanding Oracle’s Commitment to Java . . . . . . . . . . . . . . . . . . . . . 800Determining If You Should Use Java . . . . . . . . . . . . . . . . . . . . . . . . . . . 801Client-Side Java . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 802Making the Most of Server-Side Java . . . . . . . . . . . . . . . . . . . . . . . . . . . 803

The Java Cartridge (JWeb) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 803Servlets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 803Java Server Pages (JSP) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 803Enterprise Java Beans (EJB) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 804

Using Java Technologies in OAS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 804JWeb – The Java Cartridge . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 805Servlets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 818Enterprise Java Beans (EJB) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 820

Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 828

20 Perl and the Perl Cartridge . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 831Learning Perl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 833Testing and Debugging Perl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 834Using the Perl Cartridge . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 835Getting CGI Perl to Work with OAS . . . . . . . . . . . . . . . . . . . . . . . . . . . . 835Using Perl with Other Listeners . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 835Simulating a Cartridge on NT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 835

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:16 PM

Color profile: Generic CMYK printer profileComposite Default screen

xxviii Oracle8i Web Development

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xxviii

Installing and Configuring the Perl Cartridge in OWAS Version 3 . . . . . . 836Fixing the OWAS Version 3 Perl Demo . . . . . . . . . . . . . . . . . . . . . . . . . 836Installing and Configuring the Perl Cartridge in OAS Version 4 . . . . . . . 837Using a Standard CGI Library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 838Avoiding the Save As Dialog Box . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 838Displaying a List of Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 838Determining If a File Exists . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 840Creating or Appending a File . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 841Invoking a PL/SQL Procedure from Perl . . . . . . . . . . . . . . . . . . . . . . . . . 841Byteserving with Perl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 842Emulating a Browser from the Command Line . . . . . . . . . . . . . . . . . . . . 842Emulating a POST Request from the Command Line . . . . . . . . . . . . . . . 842Cleaning Up Your HTML . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 843Getting Access to Perl Documentation . . . . . . . . . . . . . . . . . . . . . . . . . . 844Looking at the Environmental Parameters . . . . . . . . . . . . . . . . . . . . . . . . 844Sending Mail from Perl . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 845Determining the Client Browser and Acting Accordingly . . . . . . . . . . . . 845Including Site Components . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 845Resolving OraPerl Reference in OWAS 3.0 Documentation . . . . . . . . . . 846Resolving OraPerl Reference in OAS 4.0 Documentation . . . . . . . . . . . 846Using Perl in the LiveHTML Cartridge . . . . . . . . . . . . . . . . . . . . . . . . . . 847Understanding OraPerl Versus DBD and DBI . . . . . . . . . . . . . . . . . . . . . 847Using OraPerl (DBD and DBI) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 848Reviewing Sample OraPerl Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 848Understanding the use OraPerl Statement . . . . . . . . . . . . . . . . . . . . . . . 849Making Database Connections Persistent . . . . . . . . . . . . . . . . . . . . . . . . 849Reviewing Production OraPerl Code . . . . . . . . . . . . . . . . . . . . . . . . . . . 850

Example with a Procedure Call . . . . . . . . . . . . . . . . . . . . . . . . . . 853Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 854Sites that Provide Perl Information . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 854

21 LiveHTML Cartridge . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 857Finding Good Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 858Setting Up the LiveHTML Cartridge . . . . . . . . . . . . . . . . . . . . . . . . . . . . 858

Enable LiveHTML . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 858Parse LiveHTML Extensions Only . . . . . . . . . . . . . . . . . . . . . . . . 859LiveHTML Extensions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 859Enable Exec Tag . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 859Enable ICX Tag . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 859Check for <BODY> Tag in ICX . . . . . . . . . . . . . . . . . . . . . . . . . . 859Default Page . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 860Enable Script Execution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 860Script Page Extension . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 860

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:16 PM

Color profile: Generic CMYK printer profileComposite Default screen

Contents xxix

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xxix

Default Scripting Language . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 860Max Requests . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 860Perl Application Library Paths . . . . . . . . . . . . . . . . . . . . . . . . . . . 861

Using Perl in LiveHTML . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 861Creating a Counter . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 862Including a Page Within a Page . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 862Calling Oracle from LiveHTML . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 862Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 863

22 Oracle Internet Commerce Server . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 865Considering Who Should Use OIC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 866Installing OIC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 867

Getting All the Pieces Installed . . . . . . . . . . . . . . . . . . . . . . . . . . 867Checking That the Installation Worked . . . . . . . . . . . . . . . . . . . . 870Figuring Out Why the Installation Might Have Failed . . . . . . . . . 872

Uninstalling OIC . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 873Thinking About Third-Party Products . . . . . . . . . . . . . . . . . . . . . . . . . . . 873Discussing the Features of the Store . . . . . . . . . . . . . . . . . . . . . . . . . . . . 874

Holding a Sale . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 875Setting Up Coupons . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 876Creating User Preferences . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 876Searching . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 876Receiving Customer Feedback . . . . . . . . . . . . . . . . . . . . . . . . . . . 877Checking Order Status . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 877

The Object Hierarchy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 878Designing Your Store Conceptually . . . . . . . . . . . . . . . . . . . . . . . . . . . . 879Creating the Store – Batch-Loading . . . . . . . . . . . . . . . . . . . . . . . . . . . . 881Maintaining the Store . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 885

Looking at the Store Manager Utility . . . . . . . . . . . . . . . . . . . . . . 885Maximizing Batch-Loading . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 888

Customizing the Store . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 892Modifying the HTML Templates . . . . . . . . . . . . . . . . . . . . . . . . . 892Creating Your Own Templates . . . . . . . . . . . . . . . . . . . . . . . . . . 900Extending the Java Classes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 901”Stepping Out” – Customization Beyond OIC . . . . . . . . . . . . . . . 906

Looking at What’s New in Version 2.0 . . . . . . . . . . . . . . . . . . . . . . . . . . 919Using the Enhanced Batch-Loader for Flat Files . . . . . . . . . . . . . . 919Enhancing Your Java Capabilities . . . . . . . . . . . . . . . . . . . . . . . . 919Bettering Your Pricing Structures . . . . . . . . . . . . . . . . . . . . . . . . . 920Using the Payment Cartridge . . . . . . . . . . . . . . . . . . . . . . . . . . . . 920

Looking at Other E-Commerce Solutions . . . . . . . . . . . . . . . . . . . . . . . . 920Comparison of BroadVision and InterWorld . . . . . . . . . . . . . . . . . . . . . . 929Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 934

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:17 PM

Color profile: Generic CMYK printer profileComposite Default screen

xxx Oracle8i Web Development

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xxx

PART VMiscellaneous

23 Utilities to Help Web Development . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 937Looking Closer at Graphics Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 939

Reviewing Paint Shop Pro (PSP) . . . . . . . . . . . . . . . . . . . . . . . . . . 939Using Animation Shop . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 941Creating Image Maps with MapEdit . . . . . . . . . . . . . . . . . . . . . . . 942Making the Most of the GIF Construction Set . . . . . . . . . . . . . . . . 944

Considering Development Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 945Determining Whether You Need a Programmers

File Editor (PFE) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 946Making the Most of TOAD . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 949Using SynEdit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 953NetObjects ScriptBuilder 3.0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . 954Understanding the Power Behind Dreamweaver . . . . . . . . . . . . . 955Thinking About HomeSite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 957Making the Most with SnadBoy Revelation . . . . . . . . . . . . . . . . . 958

Reviewing Other Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 959Understanding WS_FTP . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 959Realizing the Value of WinZip . . . . . . . . . . . . . . . . . . . . . . . . . . 961Using Traceroute . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 962Automating Content Creation . . . . . . . . . . . . . . . . . . . . . . . . . . . 963

Converting Access RDBMS to Oracle RDBMS . . . . . . . . . . . . . . . . . . . . 964Migrate Access to Oracle Tables . . . . . . . . . . . . . . . . . . . . . . . . . 965Create/Modify an ODBC Connection . . . . . . . . . . . . . . . . . . . . . 965

Directory Toolkit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 971Comparison Between Directories . . . . . . . . . . . . . . . . . . . . . . . . 971Comparison of Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 971Concatenation of Files (Combining Files) . . . . . . . . . . . . . . . . . . . 972

Anawave WebSnake . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 973Snaking 101 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 973Creating a New Project . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 974

Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 981

24 Troubleshooting . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 983You Know the Answer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 984You Know How to Find the Answer . . . . . . . . . . . . . . . . . . . . . . . . . . . . 984

Log Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 984Exception Handling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 985Books and Other Media . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 985Oracle Support . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 985Search Engines and Web Sites . . . . . . . . . . . . . . . . . . . . . . . . . . . 987

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:17 PM

Color profile: Generic CMYK printer profileComposite Default screen

You Know Who Knows the Answer . . . . . . . . . . . . . . . . . . . . . . . . . . . . 987You Know When to Ask for Help . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 987Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 988

25 Debugging Your Code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 991Reviewing General Debugging Techniques . . . . . . . . . . . . . . . . . . . . . . 993Painting the Complete Screen with PL/SQL Application . . . . . . . . . . . . . 994Determining Who Holds the Lock on a Row . . . . . . . . . . . . . . . . . . . . . 995Buying PL/SQL Debugging Tools . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 996Debugging Without Interfering with User’s View . . . . . . . . . . . . . . . . . . 996Looking Up General Oracle Errors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 997Providing Further Information than “Request Failed” . . . . . . . . . . . . . . . 997Reviewing the Log Files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 997Using Proper Error-Handling Techniques to Decrease Bug

Recovery Time . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 997Using Exception Handlers in Every Program Unit . . . . . . . . . . . . 998Recording of All Abnormal Errors . . . . . . . . . . . . . . . . . . . . . . . . 1002

Sending Error Messages to a User Interface Usingraise_application_error . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1007

Preparing for Production Problems by Designing EnhancedDebugging/Tracing Logic into Application . . . . . . . . . . . . . . . . . . . . . 1011

Presenting All Validation Errors Simultaneously Using an Error Array . . . 1016Confirming Proper Codes Using Version Reporting Package . . . . . . . . . 1020Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1023

26 Logging and Site Analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1025Getting a Basic Understanding of Web Server Usage Logging . . . . . . . . 1028Getting Further Information on Log File Formats . . . . . . . . . . . . . . . . . . 1029Looking at Web Site Management Tools . . . . . . . . . . . . . . . . . . . . . . . . 1029Reviewing the iLux Solutions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1030Comparing WebTrends Solutions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1031

WebTrends Log Analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1032Referrer Log Analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1034Agent Log Analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1034Link Analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1035

Defining the WRB Log and Listener Log . . . . . . . . . . . . . . . . . . . . . . . . . . 1036Adjusting the Severity Settings for the PL/SQL Cartridge . . . . . . . . . . . . . 1037Understanding the Logger . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1038Logging Usage to the Database . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1039Developing Your Own Reports from the Logger Tables . . . . . . . . . . . . . 1041Reviewing the XLF Logging Parameters . . . . . . . . . . . . . . . . . . . . . . . . . 1045Getting the Most Out of the Log Analyzer . . . . . . . . . . . . . . . . . . . . . . . 1045

Reporting Usage from the Database – Default XLF Reports . . . . . 1049

Contents xxxi

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xxxi

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:18 PM

Color profile: Generic CMYK printer profileComposite Default screen

Setting the Log Analyzer Parameters for User-DefinedXLF Reports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1049

Setting Log Analyzer Parameters for User-Defined SystemMessage Reports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1050

Uploading Log Files into the Database to Create User-DefinedLog Reports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1050

Summary . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1050

PART VIAppendix

A Good Sites . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1053

Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 433

xxxii Oracle8i Web Development

ORACLE Series / Oracle8i Web Development / Brown / 2242-0 / Front MatterBlind Folio FM:xxxii

Q:\Oracle8\242-0\fm.vpWednesday, November 17, 1999 1:19:18 PM

Color profile: Generic CMYK printer profileComposite Default screen