Home Page

Back to Papers


Introduction - Why WAP?

WML

XML

The Oracle XDK

An Example Application

Our first XSQL Page

Browser Sensitivity

A WML Stylesheet

WML Output

An HTML Stylesheet

Conclusion and Resources

Please note this page has moved to http://oracledoug.com/wap4.html. You will be redirected in 5 seconds but it would be better to update your bookmarks ;-)

The Oracle XML Developer's Kit

Oracle packages it's various XML development tools and Utilities as the Oracle XML Developer's Kit (XDK) which consists of the following tools, all of which can be installed inside an Oracle 8i database.

XML Parser (Java, PL/SQL, C++ and C versions available)

The most important tool in many ways is the XML parser, because it is this on which the other tools are based. It supports XML 1.0 and can be used as either a validating or non-validating parser and supports both the Simple API for XML (SAX) or Document Object Model (DOM) approaches to parsing.

XML Class Generator (Java and C++ versions available)

The XML Class generator can create source files containing class information based on a DTD so that different development teams can share class libraries that represent an agreed DTD specification.

XML SQL Utility

The XML SQL Utility is a package of Java classes that can be used to perform two complementary tasks

  • Generate an XML file and associated DTD from a database query
  • Load XML data into database tables
  • XSQL Servlet

    The tool that we'll be concentrating on is the XSQL Servlet. This is a Java servlet which is added to your web server configuration using an appropriate Servlet engine. For example, I used Apache and the Jserv module to develop the examples included in this paper, but the excellent release notes give configuration instructions for a variety of common servers.

    When the user submits a request to the server for an XSQL Page (which is identified by the .xsql extension) it passes the request off to the servlet which parses the page and forwards any SQL queries to the database. When the results are returned, it converts them to XML format and, optionally, will invoke a built-in XSL Transformation processor to render the output based on an XSQL stylesheet specified in the XSQL page. We'll see a couple of examples of XSQL pages shortly.

    At the time of writing, this toolkit is a free download from the XML software section at Technet (http://technet.oracle.com/tech/xml), but my understanding is that it will be incorporated in all future releases of the Oracle server. So all of this functionality comes for free!

    I recommend that you download the XSQL Servlet distribution, which includes the XSQL Servlet that we will be using, as well as the XML SQL Utility and the XML Parser for Java on which it is based. The Release notes that are included are excellent and include detailed instructions to help you set up the servlet in a variety of common web server environments or use the lightweight Web-to-Go server that is supplied as part of the package. You might also want to refer to a previous version of this paper that focussed on installation issues

    Previous


    Technical Papers Utilities and Scripts Book Reviews Links
    My Resume Fun & Games Email Home