O'reilly Building Oracle XML Applications.Pdf

O'reilly Building Oracle XML Applications.Pdf

Building Oracle XML Applications Steve Muench Publisher: O'Reilly First Edition September 2000 ISBN: 1-56592-691-9, 810 pages Building Oracle XML Applications gives Java and PL/SQL developers a rich and detailed look at the many tools Oracle provides to support XML development. It shows how to combine the power of XML and XSLT with the speed, functionality, and reliability of the Oracle database. The author delivers nearly 800 pages of entertaining text, helpful and time-saving hints, and extensive examples that developers can put to use immediately to build custom XML applications. The accompanying CD-ROM contains JDeveloper 3.1, an integrated development environment for Java developers. Building Oracle XML Applications Copyright © 2000 O'Reilly & Associates, Inc. All rights reserved. Printed in the United States of America. Published by O'Reilly & Associates, Inc., 101 Morris Street, Sebastopol, CA 95472. The O'Reilly logo is a registered trademark of O'Reilly & Associates, Inc. Many of the designations used by manufacturers and sellers to distinguish their products are claimed as trademarks. Where those designations appear in this book, and O'Reilly & Associates, Inc. was aware of a trademark claim, the designations have been printed in caps or initial caps. Oracle®, JDeveloper™, and all Oracle-based trademarks and logos are trademarks or registered trademarks of Oracle Corporation, Inc. in the United States and other countries. Java™ and all Java-based trademarks and logos are trademarks or registered trademarks of Sun Microsystems, Inc. in the United States and other countries. O'Reilly & Associates, Inc. is independent of Oracle Corporation and Sun Microsystems. While every precaution has been taken in the preparation of this book, the publisher assumes no responsibility for errors or omissions, or for damages resulting from the use of the information contained herein. Table of Contents Preface Audience for This Book Which Platform and Version? Structure of This Book About the Examples About the CD-ROM Conventions Used in This Book Comments and Questions Acknowledgments I: XML Basics 1. Introduction to XML 1.1 What Is XML? 1.2 What Can I Do with XML? 1.3 Why Should I Use XML? 1.4 What XML Technologies Does Oracle Provide? 2. Working with XML 2.1 Creating and Validating XML 2.2 Modularizing XML 2.3 Searching XML with XPath II: Oracle XML Fundamentals 3. Combining XML and Oracle 3.1 Hosting the XML FAQ System on Oracle 3.2 Serving XML in Any Format 3.3 Acquiring Web-based XML Content 4. Using JDeveloper for XML Development 4.1 Working with XML, XSQL, and JSP Files 4.2 Working with Database Objects 4.3 Using JDeveloper with Oracle XDK Components 5. Processing XML with PL/SQL 5.1 Loading External XML Files 5.2 Parsing XML 5.3 Searching XML Documents with XPath 5.4 Working with XML Messages 5.5 Producing and Transforming XML Query Results 6. Processing XML with Java 6.1 Introduction to Oracle8 i JServer 6.2 Parsing and Programmatically Constructing XML 6.3 Searching XML Documents with XPath 6.4 Working with XML Messages 6.5 Producing and Transforming XML Query Results 7. Transforming XML with XSLT 7.1 XSLT Processing Mechanics 7.2 Single-Template Stylesheets 7.3 Understanding Input and Output Options 7.4 Improving Flexibility with Multiple Templates 8. Publishing Data with XSQL Pages 8.1 Introduction to XSQL Pages 8.2 Transforming XSQL Page Results with XSLT 8.3 Troubleshooting Your XSQL Pages 9. XSLT Beyond the Basics 9.1 Using XSLT Variables 9.2 The Talented Identity Transformation 9.3 Grouping Repeating Data Using SQL 9.4 Sorting and Grouping Repeating Data with XSLT 10. Generating Datagrams with PL/SQL 10.1 Programmatically Generating XML Using PL/SQL 10.2 Automatic XML Generation with DBXML 11. Generating Datagrams with Java 11.1 Generating XML Using Java 11.2 Serving XML Datagrams over the Web 11.3 Automatic XML from SQL Queries 12. Storing XML Datagrams 12.1 Overview of XML Storage Approaches 12.2 Loading Datagrams with the XML SQL Utility 12.3 Storing Posted XML Using XSQL Servlet 12.4 Inserting Datagrams Using Java 13. Searching XML with interMedia 13.1 Why Use interMedia? 13.2 What Is interMedia? 13.3 The interMedia Query Language 13.4 Handling Heterogeneous Doctypes 13.5 Handling Doctype Evolution 13.6 Advanced interMedia 14. Advanced XML Loading Techniques 14.1 Storing Datagrams in Multiple Tables 14.2 Building an XMLLoader Utility 14.3 Creating Insert Transformations Automatically III: Oracle XML Applications 15. Using XSQL Pages as a Publishing Framework 15.1 Overview of XSQL Pages Facilities 15.2 Additional XML Delivery Options 16. Extending XSQL and XSLT with Java 16.1 Developing Custom XSQL Actions 16.2 Integrating Custom XML Sources 16.3 Working with XSLT Extension Functions 17. XSLT-Powered Portals and Applications 17.1 XSLT-Powered Web Store 17.2 Building a Personalized News Portal 17.3 Online Discussion Forum IV: Appendixes A. XML Helper Packages A.1 Installing the XML Helper Packages A.2 Source Code for the XML Helper Packages B. Installing the Oracle XSQL Servlet B.1 Supported Configurations B.2 Prerequisites B.3 Downloading and Installing the XSQL Servlet C. Conceptual Map to the XML Family D. Quick References Colophon Preface This book is a hands-on, practical guide that teaches you the nuts and bolts of XML and the family of Internet standards related to it and shows how to exploit XML with your Oracle database using Java™, PL/SQL, and declarative techniques. It’s a book for Oracle developers by an Oracle developer who has lived the technology at Oracle Corporation for over ten years and has directly catalyzed the company’s XML technology direction and implementation. As you read this book, I hope you will come to appreciate the wide variety of tools Oracle provides to enable you to combine the best of XML with the best of Oracle to build flexible, database-powered applications for the Web. This book abounds with tested, commented, and fully explained examples because—in the unforgettable words of a high school mentor of mine—“you only get good at something by working through an ungodly number of problems." The examples include a number of helper libraries and utilities that will serve to jump-start your own Oracle XML development projects (see “About the Examples" later in this Preface for details). If this book has one main goal, it is to educate, excite, and thoroughly convince you that by combining: • The speed, functionality, and reliability of the Oracle database • The power of XML as a universal standard for data exchange • The flexibility to easily transform XML data into any format required we can accomplish some pretty amazing things, not to mention saving ourselves a lot of work in the process. Audience for This Book This book is aimed mainly at Java and PL/SQL developers who want to use the XML family of Internet standards in conjunction with their Oracle databases. I also expect that this book may catch the eye of existing Oracle database administrators who want to update their skills to learn how to apply Java, PL/SQL, and XML to their daily work. In addition, the in-depth coverage of Oracle’s template-driven XSQL Pages technology should prove useful to non-programmers as well. This book assumes no prior knowledge of XML on your part, but it does assume a basic working knowledge of SQL and familiarity with either Java or PL/SQL as a programming language. Which Platform and Version? Much of this book applies to Oracle8 and Oracle8i (and even Oracle7 in some cases). In general, if you want to use XML outside the database, you can use any Oracle version. However, if you want to use XML features inside the database (and take full advantage of the features I describe here), you must use Oracle8i. Wherever relevant, I note whether a particular XML feature is specific to Oracle8i or can be used with earlier Oracle versions as well. The examples for this book were developed and tested on a Windows NT 4.0 platform using JDeveloper 3.1 as a development environment and Oracle8i Release 2 Enterprise Edition for NT (version 8.1.6 ) as the database. However, none of the examples, tools, or technologies covered in the book are Windows-specific. The JDeveloper 3.1 product—included on the CD-ROM that accompanies this book—is certified to run on Windows NT and Windows 2000. Structure of This Book This book is not divided strictly by individual tool and function. Instead, it begins in Part I with an overview of fundamental XML standards and concepts. Part II covers all core Oracle XML technologies, presenting increasingly detailed discussions of various Oracle XML capabilities. Part III describes combining the technologies we’ve learned to build applications and portals. Finally, Part IV includes four useful appendixes with installation and reference information. The book uses extensive examples—in both PL/SQL and Java—to present material of increasing sophistication. The following list summarizes the contents in detail. Part I, introduces the basics of XML and provides a high-level overview of Oracle’s XML technology. It consists of the following chapters: • Chapter 1, provides a gentle introduction to XML by describing what it is, what you can do with it, why you should use it, and what software Oracle supplies to work with it. • Chapter 2, describes how to build your own “vocabularies" of tags to represent the information you need to work with, as well as how to use XML namespaces and entities to modularize your documents and XPath expressions to search them.

View Full Text

Details

  • File Type
    pdf
  • Upload Time
    -
  • Content Languages
    English
  • Upload User
    Anonymous/Not logged-in
  • File Pages
    883 Page
  • File Size
    -

Download

Channel Download Status
Express Download Enable

Copyright

We respect the copyrights and intellectual property rights of all users. All uploaded documents are either original works of the uploader or authorized works of the rightful owners.

  • Not to be reproduced or distributed without explicit permission.
  • Not used for commercial purposes outside of approved use cases.
  • Not used to infringe on the rights of the original creators.
  • If you believe any content infringes your copyright, please contact us immediately.

Support

For help with questions, suggestions, or problems, please contact us