In a case like this, you aren’t doing a lot of work on the data. The data is the same, and the results are in the same order. You just want to present the results in a better way. All you need is a way to transform the results that come back from the database into what you want. The ideal situation is shown in Figure 1.3. This is where XSQL and XSLT come in. XSLT will take an XML document and transform it into whatever you want. It is an open-standards solution to the problem of merging dynamic data with static HTML. This usually means transforming it into HTML, but you aren’t limited to just that. For instance, in Chapter 15, you’ll see how you can use XSLT to write scripts based on database data. If you know cascading style sheets (CSS), then you have a head start in understanding XSLT. If you are familiar with Server Side Includes, you can consider XSLT as Server Side Includes on steroids. XSLT is almost always used in com- bination with XSQL in some way. The core architecture is shown in Figure 1.4. To get a better idea of how SQL, XSQL, and XSLT work together, here is some sam- ple code. These two files are all you need to produce the Web page that was shown pre- viously in Figure 1.2. The first file is the XSQL page. The  <xsql:query>  element, which is called an action, defines the SQL query that you need: <?xml version=”1.0”?> <?xml-stylesheet type=”text/xsl” href=”emp-intro.xsl”?> <page xmlns:xsql=”urn:oracle-xsql” connection=”demo”> <xsql:query> SELECT ename, job, sal FROM emp WHERE deptno=20 ORDER BY sal </xsql:query> </page> Figure 1.3 Transforming SQL results. Client Web Page Database SQL Query SELECT ename, job, sal FROM emp WHERE deptno=20 ORDER BY sal Transformation Module Template SQL Result Set ENAME SMITH ADAMS JONES SCOTT FORD JOB CLERK CLERK MANAGER ANALYST ANALYST SAL 800 1100 2975 3000 3000 Introducing Oracle XSQL 7 271209 Ch01.F  12/9/02  2:00 PM  Page 7