Author: ochikvina
Date: 2009-04-08 04:18:42 -0400 (Wed, 08 Apr 2009)
New Revision: 14591
Added:
trunk/birt/docs/en/modules/birt_integration_with_seam.xml
trunk/birt/docs/en/modules/birt_reports_deployment.xml
trunk/birt/docs/en/modules/hibernate_datasource.xml
Log:
https://jira.jboss.org/jira/browse/JBDS-687 - the guide is restructured;
Added: trunk/birt/docs/en/modules/birt_integration_with_seam.xml
===================================================================
--- trunk/birt/docs/en/modules/birt_integration_with_seam.xml (rev
0)
+++ trunk/birt/docs/en/modules/birt_integration_with_seam.xml 2009-04-08 08:18:42 UTC (rev
14591)
@@ -0,0 +1,360 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<chapter id="birt_integration_with_seam"
xreflabel="birt_integration_with_seam">
+
+ <?dbhtml filename="birt_integration_with_seam.html"?>
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss</keyword>
+ <keyword>BIRT</keyword>
+ <keyword>Seam</keyword>
+ </keywordset>
+ </chapterinfo>
+ <title>Adding BIRT Functionality to Standard Seam Web Project</title>
+
+ <para>In this chapter you'll know how to create a Seam web project
with BIRT
+ capabilities included.</para>
+
+ <para>You are supposed to have Seam runtime and JBoss Application Server
downloaded and
+ extracted somewhere on you hard drive.</para>
+
+ <tip>
+ <title>Tip:</title>
+ <para><ulink
+
url="http://sourceforge.net/project/showfiles.php?group_id=22866&...
+ >JBoss Seam 2.0.1 GA</ulink> and <ulink
+
url="http://sourceforge.net/project/showfiles.php?group_id=22866&...
+ >JBoss Application Server 4.2.2 GA</ulink> are
required.</para>
+ </tip>
+
+ <section id="creatin_project_with_birt">
+ <title>Creating Seam Web Project with Birt Facet</title>
+
+ <para>First, open <property>Seam perspective</property> by
going to <emphasis>
+ <property>Window > Open Perspective > Other >
Seam</property>.
+ </emphasis> To create a new Seam Web project follow to
<emphasis>
+ <property>File > New > Seam Web
Project</property>
+ </emphasis> (or <emphasis>
+ <property>File > New > Other > Seam >
Seam Web
+ Project</property>
+ </emphasis> if you are not in the <property>Seam
perspective</property>).</para>
+
+ <para>On the first wizard page enter the project name, then specify the
target runtime and
+ target server. In the <emphasis>
+ <property>Configuration</property>
+ </emphasis> section click <emphasis>
+ <property>Modify</property>
+ </emphasis> to configure the project facets.</para>
+
+ <figure>
+ <title>Creating Seam Web Project</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/birt_integration_with_seam/testBirtProject.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Choose the 2.0 version of the <emphasis>
+ <property>Seam</property>
+ </emphasis> facet and enable the <emphasis>
+ <property>Birt Reporting Runtime Component</property>
+ </emphasis> facet.</para>
+
+ <figure>
+ <title>Adding the Birt Reporting Runtime Component Facet
</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/birt_integration_with_seam/addingBirtFacet.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Or you can just choose the <emphasis>
+ <property>JBoss BIRT Integration Web Project</property>
+ </emphasis> configuration.</para>
+
+ <figure>
+ <title>Choosing the JBoss BIRT Integration Web Project
Configuration</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
+
fileref="images/birt_integration_with_seam/projectBirtConfiguration.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Next three pages are filled out with defaults, just leave them
through by pressing <emphasis>
+ <property>Next</property>.</emphasis> On the
<emphasis>
+ <property>Seam Facet</property>
+ </emphasis> page you should specify the Seam runtime and Connection
profile.</para>
+
+ <figure>
+ <title>Configuring the Seam Facet settings</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/birt_integration_with_seam/seamFacet.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Hit <emphasis>
+ <property>Finish</property>
+ </emphasis> to create the project with Birt functionality
enabled.</para>
+ </section>
+
+ <section id="integration">
+ <title>Integration with Seam</title>
+
+ <para>The JBoss BIRT Integration feature contains the BIRT tag that allows
the user to add a
+ BIRT report to an <emphasis>
+ <property>.xhtml</property>
+ </emphasis> file:</para>
+
+ <programlisting role="XHTML"><![CDATA[<p:birt
xmlns:ui="http://java.sun.com/jsf/facelets"
+
xmlns:s="http://jboss.com/products/seam/taglib"
+
xmlns:p="http://jboss.com/products/seam/birt"
+ designType="run"
+ format="pdf"
+ designName="test.rptdesign"
+ title="JBoss Birt Test">
+
+</p:birt>]]></programlisting>
+
+ <para>Let's look how it works.</para>
+ <para>Create in the <emphasis>
+ <property>Web Content</property>
+ </emphasis> folder three <emphasis>
+ <property>.xhtml</property>
+ </emphasis> pages with the following content:</para>
+
+ <itemizedlist>
+ <listitem>
+ <para>
+ <emphasis>
+
<property>birttests.xhtml</property>:</emphasis>
+ </para>
+ <programlisting role="XHTML"><![CDATA[<!DOCTYPE
composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+ <ui:composition
xmlns="http://www.w3.org/1999/xhtml"
+
xmlns:s="http://jboss.com/products/seam/taglib"
+
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:f="http://java.sun.com/jsf/core"
+
xmlns:h="http://java.sun.com/jsf/html"
+
xmlns:rich="http://richfaces.org/rich"
+ template="layout/template.xhtml">
+
+ <ui:define name="body">
+ <h:messages globalOnly="true"
styleClass="message"/>
+ <rich:panel>
+ <f:facet name="header">Welcome to JBoss
BIRT!</f:facet>
+ <ul>
+ <li><s:link view="/testbirt.xhtml"
value="Test Birt" /></li>
+ <li><s:link
view="/testbirt1.xhtml" value="Test Birt 1" /></li>
+ </ul>
+ </rich:panel>
+ </ui:define>
+ </ui:composition>]]></programlisting>
+ </listitem>
+ <listitem>
+ <para>
+ <emphasis>
+
<property>testbirt.xhtml</property>:</emphasis>
+ </para>
+ <programlisting role="XHTML"><![CDATA[<p:birt
xmlns:ui="http://java.sun.com/jsf/facelets"
+
xmlns:s="http://jboss.com/products/seam/taglib"
+
xmlns:p="http://jboss.com/products/seam/birt"
+ designType="run"
+ format="pdf"
+ designName="test.rptdesign"
+ title="JBoss Birt Test">
+
+ <p:param name="sample" value="sample
param"/>
+</p:birt>]]></programlisting>
+ </listitem>
+ <listitem>
+ <para>
+ <emphasis>
+
<property>testbirt1.xhtml</property>:</emphasis>
+ </para>
+ <programlisting role="XHTML"><![CDATA[<p:birt
xmlns:ui="http://java.sun.com/jsf/facelets"
+
xmlns:s="http://jboss.com/products/seam/taglib"
+
xmlns:p="http://jboss.com/products/seam/birt"
+ designType="frameset"
+ designName="test1.rptdesign"
+ title="JBoss Birt Test">
+</p:birt>]]></programlisting>
+ </listitem>
+ </itemizedlist>
+
+ <para>Now start the application server by clicking the <emphasis>
+ <property>Start</property>
+ </emphasis> option in the context menu of the server in the
<property>JBoss Server
+ View</property> (if the view isn't open go to
<emphasis>
+ <property>Window > Show View > Other > JBoss
Server
+ View</property>)</emphasis>. Try the tests out by
accessing <emphasis>
+
<property>http://localhost:8080/hellobirt/birttests.seam</property>
+ </emphasis> in your web browser.</para>
+
+ <figure>
+ <title>Welcome Page in the Browser</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/birt_integration_with_seam/birttestsPage.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Now if you click <emphasis>
+ <property>Test Birt</property>
+ </emphasis> you should see the following <emphasis>
+ <property>.pdf</property>
+ </emphasis> file:</para>
+
+ <figure>
+ <title>After Clicking Test Birt</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/birt_integration_with_seam/testbirtPage.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>After clicking <emphasis>
+ <property>Test Birt 1</property>
+ </emphasis> the next page is displayed:</para>
+
+ <figure>
+ <title>After Clicking Test Birt 1</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/birt_integration_with_seam/testbirt1Page1.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Put the <emphasis>
+ <property>test param</property>
+ </emphasis> as Sample Parameter value, specify the maximum possible
Customer Number as
+ <emphasis>
+ <property>1001</property>,</emphasis> for instance, and
then press <emphasis>
+ <property>Ok</property>.</emphasis> You'll see
the following BIRT
+ report:</para>
+
+ <figure>
+ <title>BIRT Report in the Browser Window</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/birt_integration_with_seam/testbirt1Page2.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>The BIRT tag recognizes most of the parameters described on
<ulink
+
url="http://www.eclipse.org/birt/phoenix/deploy/viewerUsage2.2.php#p...
+ BIRT Report Viewer Parameters page</ulink>. The attributes of the
BIRT tag
+ don't contain the <emphasis>
+ <property>"__"</property>
+ </emphasis> prefix.</para>
+
+ <para>The <emphasis>
+ <property>param</property>
+ </emphasis> tag describes report parameters (see the listing for the
<emphasis>
+ <property>testbirt.xhtml</property>
+ </emphasis> above). It supports the following attributes:
</para>
+ <itemizedlist>
+ <listitem>
+ <para><emphasis>
+ <property>name</property>
+ </emphasis> - the parameter name (required)</para>
+ </listitem>
+ <listitem>
+ <para><emphasis>
+ <property>value</property>
+ </emphasis> - the parameter value (required)</para>
+ </listitem>
+ <listitem>
+ <para><emphasis>
+ <property>isnull</property>
+ </emphasis> - specifies that a report parameter has a null
value
+ (optional)</para>
+ </listitem>
+ <listitem>
+ <para><emphasis>
+ <property>islocale</property>
+ </emphasis> - specifies whether the parameter is localized
(optional)</para>
+ </listitem>
+ </itemizedlist>
+
+ <para>These tags are defined in the <emphasis>
+
<property>org.jboss.birt.core/resources/jboss-seam-birt.jar</property>
+ </emphasis> library that contains source. </para>
+
+ <!--para>It is also possible to embed a BIRT report in some Seam
<emphasis>
+ <property>.xhtml</property>
+ </emphasis> page. See how it may be done:</para>
+ <para/>
+
+ <para>
+ <emphasis role="bold">Example:</emphasis>
+ </para>
+ <programlisting role="XHTML"><![CDATA[<!DOCTYPE composition
PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
+
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+ <ui:composition
xmlns="http://www.w3.org/1999/xhtml"
+
xmlns:s="http://jboss.com/products/seam/taglib"
+
xmlns:ui="http://java.sun.com/jsf/facelets"
+
xmlns:f="http://java.sun.com/jsf/core"
+
xmlns:h="http://java.sun.com/jsf/html"
+
xmlns:rich="http://richfaces.org/rich"
+
xmlns:b="http://jboss.com/products/seam/birt"
+ template="layout/template.xhtml">
+ <ui:define name="body">
+ <h:messages globalOnly="true" styleClass="message"
id="globalMessages"/>
+ <rich:panel>
+ <f:facet name="header">Products</f:facet>
+ <b:birt designType="embed"
designName="ProductCatalog.rptdesign"
+ embeddable="true"
masterpage="false"/>
+ <div style="clear:both"/>
+ </rich:panel>
+ <div class="actionButtons">
+ <s:button view="/ProductsEdit.xhtml"
id="edit" value="Edit"/>
+ <s:button view="/BirtProductsPdf.xhtml"
+ id="BirtProductPdf"
value="Product Catalog - PDF"/>
+ <s:button view="/BirtProductsFrameset.xhtml"
+ id="BirtProductFrameset"
value="Product Catalog - Frameset"/>
+ <s:button view="/BirtProductsEmbedded.xhtml"
+ id="BirtProductEmbedded"
value="Product Catalog - Embedded"/>
+ <s:button view="/TopSellingProducts.xhtml"
+ id="TopSellingProducts"
value="Top Selling Products"/>
+ <s:button view="/#{empty productsFrom ?
'ProductsList' : productsFrom}.xhtml"
+ id="done"
value="Done"/>
+ </div>
+ </ui:define>
+ </ui:composition>]]></programlisting>
+
+ <figure>
+ <title>Embedding BIRT Report in Seam xhtml Page. First
Page</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/BirtIntegration/BirtReportInSeamPage1.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <figure>
+ <title>Embedding BIRT Report in Seam xhtml Page. Second
Page</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/BirtIntegration/BirtReportInSeamPage2.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <figure>
+ <title>Embedding BIRT Report in Seam xhtml Page. Third
Page</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/BirtIntegration/BirtReportInSeamPage3.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure-->
+ </section>
+</chapter>
Added: trunk/birt/docs/en/modules/birt_reports_deployment.xml
===================================================================
--- trunk/birt/docs/en/modules/birt_reports_deployment.xml (rev
0)
+++ trunk/birt/docs/en/modules/birt_reports_deployment.xml 2009-04-08 08:18:42 UTC (rev
14591)
@@ -0,0 +1,122 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<chapter id="birt_reports_deployment"
xreflabel="birt_reports_deployment">
+
+ <?dbhtml filename="birt_reports_deployment"?>
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss</keyword>
+ <keyword>BIRT</keyword>
+ <keyword>Seam</keyword>
+ </keywordset>
+ </chapterinfo>
+
+ <title>BIRT Reports Deployment</title>
+
+ <para>When everything is configured correctly you will be able to view/render
the designed
+ reports in your Seam (or any other) Web application.</para>
+
+ <para>You can deploy a report by adding an action button to the Seam's
CRUD <emphasis>
+ <property>.xhtml</property>
+ </emphasis> file.</para>
+
+ <figure>
+ <title>Adding Action Button to the Seam file</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/birt_reports_deployment/addingActionButton.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>As you can see on the figure you should have the <emphasis>
+ <property>testHibernateOda.xhtml</property>
+ </emphasis> file. It's content should be the
following:</para>
+
+ <programlisting role="XHTML"><![CDATA[<p:birt
xmlns:ui="http://java.sun.com/jsf/facelets"
+
xmlns:s="http://jboss.com/products/seam/taglib"
+
xmlns:p="http://jboss.com/products/seam/birt"
+ designType="run"
+ format="pdf"
+ designName="testHibernateOda.rptdesign"
+ title="JBoss Birt Test">
+
+</p:birt>
+]]></programlisting>
+
+ <para>Next run the Seam page with embedded report on the server by
right-clicking the file and
+ going to <emphasis>
+ <property>Run > Run on
Server</property>.</emphasis></para>
+
+ <figure>
+ <title>Opening Employees.xhtml Page</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/birt_reports_deployment/openingArticlesPage.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>After clicking the <emphasis>
+ <property>BIRT PDF Report</property>
+ </emphasis> button, you should see the following report:</para>
+
+ <figure>
+ <title>Birt PDF Report</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/birt_reports_deployment/BirtPDFReport.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Thus, a Seam project that includes the BIRT facet can be deployed as any
project. If you
+ define the Hibernate ODA driver, the JBoss BIRT engine will use JNDI URL that has
to be bind
+ to either Hibernate Session Factory or Hibernate Entity Manager Factory. If you
+ don't specify the JNDI URL property, our engine will try the following
JNDI
+ URLs:</para>
+ <itemizedlist>
+ <listitem>
+ <para>
+ <emphasis>java:/<project_name></emphasis>
+ </para>
+ </listitem>
+ <listitem>
+ <para>
+
<emphasis>java:/<project_name>EntityManagerFactory</emphasis>
+ </para>
+ </listitem>
+ </itemizedlist>
+
+ <para>When creating a Seam EAR project, Hibernate Entity Manager Factory is
bound to
+ <emphasis>java:/{projectName}EntityManagerFactory</emphasis>. All
you need to do is
+ using the Hibernate Configuration created automatically. You can use default
values for the
+ Hibernate Configuration and JNDI URL within the BIRT Hibernate Data
Source.</para>
+
+ <para>When using a Seam WAR project, neither HSF nor HEMF aren't
binded to JNDI by
+ default. You has to do this manually. For instance, HSF can be bound to JNDI by
adding the
+ following property to the <emphasis>
+ <property>persistence.xml</property></emphasis>
file:</para>
+
+ <programlisting role="XHTML"><![CDATA[<property
name="hibernate.session_factory_name" value="java:/projectname"/>
+ ]]></programlisting>
+
+ <para>And you can use <emphasis>java:/projectname</emphasis> as the
JNDI URL property when creating a BIRT
+ Hibernate Data Source.</para>
+
+ <note>
+ <title>Note:</title>
+ <para>If you want to test this feature using PDE Runtime, you need to add
<emphasis>
+ <property>osgi.dev=bin</property>
+ </emphasis> to the <emphasis>
+
<property>WebContent/WEB-INF/platform/configuration/config.ini</property>
+ </emphasis> file.</para>
+ </note>
+ <para>In conclusion, the main goal of this document is to get you know with a
full featureset
+ that <property>JBoss BIRT Tools</property> provide. Thus if you have
some questions,
+ comments or suggestions on the topic, please feel free to ask in the <ulink
+
url="http://www.jboss.org/index.html?module=bb&op=viewforum&...
+ Tools Forum</ulink>. You can also influence on how you want to see
JBoss Tools docs in
+ future leaving your vote on our page <ulink
+
url="http://www.jboss.org/community/docs/DOC-10795">here<...
+
+</chapter>
Added: trunk/birt/docs/en/modules/hibernate_datasource.xml
===================================================================
--- trunk/birt/docs/en/modules/hibernate_datasource.xml (rev 0)
+++ trunk/birt/docs/en/modules/hibernate_datasource.xml 2009-04-08 08:18:42 UTC (rev
14591)
@@ -0,0 +1,239 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<chapter id="hibernate_datasource"
xreflabel="hibernate_datasource">
+
+ <?dbhtml filename="hibernate_datasource.html"?>
+ <chapterinfo>
+ <keywordset>
+ <keyword>JBoss</keyword>
+ <keyword>BIRT</keyword>
+ <keyword>Seam</keyword>
+ </keywordset>
+ </chapterinfo>
+
+ <title>Hibernate ODA Data Source</title>
+
+ <para>The JBoss BIRT Integration feature includes the Hibernate ODA Data Source
completely
+ integrated with Hibernate Tools. You can use it in the way you use any of BIRT
ODA drivers.
+ Let's perform simple actions that demonstrate it.</para>
+
+ <para>First, run the <emphasis>
+ <property>Seam Generate Entities</property>
+ </emphasis> action (You can access it from <emphasis>
+ <property>File > New > Seam Generate
Entities</property>
+ </emphasis> in the <property>Seam perspective</property>. More
details on the Seam Generate
+ Entities read in our <ulink
+
url="http://download.jboss.org/jbosstools/nightly-docs/en/seam/html_...
+ >Seam Dev Tools Reference guide</ulink>). This action will create a
Hibernate Console
+ configuration.</para>
+
+ <tip>
+ <title>Tip:</title>
+ <para>Before performing Seam Generate Entities, you should have a
connection profile
+ adjusted and connected to a database. How to do this see in the <ulink
+
url="http://download.jboss.org/jbosstools/nightly-docs/en/seam/html_...
+ >CRUD Database Application</ulink> chapter of the Seam Dev Tools
Reference
+ guide.</para>
+ </tip>
+
+ <para>Next add a new BIRT report. To do that navigate to <emphasis>
+ <property>File > New > Other > Business
Intelligence and Reporting
+ Tools > Report</property>.</emphasis> In the
<property>New Report
+ wizard</property> enter the report name, for instance <emphasis>
+ <property>testHibernateOda.rptdesign</property>,</emphasis>
then click <emphasis>
+ <property>Finish</property>.</emphasis></para>
+
+ <figure>
+ <title>Creating a New BIRT Report </title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/hibernate_datasource/creatingNewBirtReport.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Now switch to the <property>Report Design
perspective</property>.</para>
+
+ <para>In the <property>Data Explorer View</property> right-click
the <emphasis>
+ <property>Data Source</property>
+ </emphasis> node and choose <emphasis>
+ <property>New Data
Source</property>.</emphasis></para>
+
+ <figure>
+ <title>Creating a New Data Source</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/hibernate_datasource/creatingDataSource.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>In the wizard select <emphasis>
+ <property>Hibernate Data Source</property>
+ </emphasis> and give it a proper name, <emphasis>
+ <property>HbDataSource</property>
+ </emphasis> for instance. Hit <emphasis>
+ <property>Next</property>.</emphasis></para>
+
+ <figure>
+ <title>Creating Hibernate Data Source</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/hibernate_datasource/hibernateDataSource.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>On the next wizard page leave everything as it is, just press the
<emphasis>
+ <property>Test Connection</property>
+ </emphasis> button to verify the connection is successful.</para>
+
+ <figure>
+ <title>Hibernate Data Source Profile</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/hibernate_datasource/connectionSuccessful.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Click <emphasis>
+ <property>Ok</property>
+ </emphasis> and then <emphasis>
+ <property>Finish</property>
+ </emphasis> to complete.</para>
+
+ <para>Now let's add a Hibernate ODA dataset. To do that you should
bring up the
+ <property>New Data Set wizard</property>. In the
<property>Data Explorer View</property>
+ right-click the <emphasis>
+ <property>Data Set</property>
+ </emphasis> node and select <emphasis>
+ <property>New Data Set</property>.</emphasis></para>
+
+ <figure>
+ <title>Creating a New Data Set</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/hibernate_datasource/creatingDataSet.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>In the <emphasis>
+ <property>Data Set Name</property>
+ </emphasis> section specify the name. Let's it be
<emphasis>
+ <property>HbDataSet</property>.</emphasis></para>
+
+ <figure>
+ <title>Creating a Hibernate ODA Data Set</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/hibernate_datasource/addingHibernateODADataset.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Next you'll be prompted to define the query for this data set.
To validate the
+ entered query you can press the <emphasis>
+ <property>Test query</property>
+ </emphasis> button. All the HQL features like syntax highlighting, content
assist,
+ formatting, Drag and Drop, etc., are available to you here.</para>
+
+ <figure>
+ <title>Testing Query </title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/hibernate_datasource/testingQuery.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Next the output columns will be displayed. It's possible to edit
them
+ here.</para>
+
+ <figure>
+ <title>HQL Features - Output Columns Section</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/hibernate_datasource/hqlFeaturesOutputColumns.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>To preview the results of the defined query click the <emphasis>
+ <property>Preview Results</property>
+ </emphasis> item.</para>
+ <figure>
+ <title>HQL Features - Preview Results Section</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/hibernate_datasource/hqlFeaturesPreviewResults.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>So far you have the Hibernate data source and data set defined. Now you
can create a BIRT
+ report using this data source and data set.</para>
+
+ <tip>
+ <title>Tip:</title>
+ <para>If you don't know how to do this we suggest that you refer
to the <ulink
+
url="http://www.eclipse.org/birt/phoenix/tutorial/">Eclipse
BIRT Tutorial</ulink>.</para>
+ </tip>
+
+ <figure>
+ <title>Creating a BIRT Report using Created Data Source and Data
Set</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
+
fileref="images/hibernate_datasource/BIRTReportUsingDataSourceAndSet.png "/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>If you switch to the <emphasis>
+ <property>Preview</property></emphasis> tab, it will run your
report and show the output.</para>
+
+ <figure>
+ <title>BIRT Report -Preview Tab</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/hibernate_datasource/BIRTReportPreviewTab.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>You can also use parameters within the Hibernate ODA
driver.</para>
+
+ <figure>
+ <title>Using Parameters within the Hibernate ODA Driver</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
+
fileref="images/hibernate_datasource/parametersWithinHibernateODADriver.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+
+ <figure>
+ <title>Adding New Parameter</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/hibernate_datasource/addingNewParameter.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ <para>Again, to preview the results switch to the <emphasis>
+ <property>Preview Results</property>
+ </emphasis> item.</para>
+ <figure>
+ <title>Previewing the Results</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata
fileref="images/hibernate_datasource/previewingResults.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+</chapter>