Purpose
This tutorial mainly covers how Oracle BI Publisher is integrated with Oracle Business Intelligence Enterprise Edition (Oracle BI EE) 10.1.3.2, and how this integration enables you to create highly formatted reports in Oracle BI Publisher by using Oracle BI Answers and Oracle BI Server metadata.
Overview
About Oracle Business Intelligence Enterprise Edition:
Oracle Business Intelligence Suite Enterprise Edition (Oracle BI EE) offers an integrated, comprehensive, standards-based BI platform that provides the best foundation for building enterprise wide BI solutions. It leverages the Oracle's existing data warehousing and business intelligence tools, with a new stack of products listed here.
Oracle Business Intelligence Enterprise Edition specifically consists of:
Oracle BI Server: Centralized data access and calculation via a logical Common Enterprise Information Model through to the end-user products and other SQL-based tools | |
Oracle BI Interactive Dashboards: Personalized, highly intuitive, guided and fully interactive access to cockpits of live analyses | |
Oracle BI Answers: Self-service ad hoc capabilities allowing end users to easily create charts, pivot tables, reports, and visually appealing dashboards, all of which are fully interactive and drillable | |
Oracle BI Delivers: Proactive intelligence solution providing alerts that can reach users via multiple channels (e-mail, dashboards, and mobile devices), as well as workflow integration | |
Oracle BI Disconnected Analytics: Full business intelligence functionality for the mobile professional, enabling fully interactive dashboards and ad hoc analysis while disconnected from the corporate network | |
Oracle BI Publisher: High-fidelity report templates that are created and published via common personal productivity applications delivered directly or through Interactive Dashboards to end users |
In this tutorial, you start by opening an existing BI Answers request and modify that to add more fields. You connect to BI Publisher from MS Word and save the BI Answers request that you created as a BI Publisher report. You will open a simple RTF file and create a layout for the report with charts and table using the wizards in MS Word. You will publish this template for the BI Publisher report, and also, you will publish a BI Publisher report on a BI Dashboard. You will also be guided to create a BI Publisher report based on from BI Server subject area and view the data.
Scenario
This OBE uses the sales history metadata repository SH.rpd, based on the Sales History (SH) sample schema of Oracle Database. To continue with the steps listed in the topics, you should have installed the required software, and set up theSH.rpd metadata repository, as mentioned in the topic titled "Prerequisites."
Before starting this tutorial, you should:
1. |
Have access to or installed Oracle Database 10g (preferably version 10.2 )
|
2. |
Have access to or have installed the SH sample schema.
This OBE uses the SH schema included in the Oracle10g Database.
|
3. | Have access to or have installed Oracle BI EE 10.1.3.2 including Oracle BI Publisher and Oracle BI Publisher Desktop 10.1.3.2. You can follow the instructions as listed in this OBE " Installing the Oracle Business Intelligence Enterprise Edition on Windows " |
4. |
Have created an ODBC connection to the Oracle database, and set up the SH.rpd metadata repository, following the steps listed in the OBE "Creating Interactive Dashboards and Using Oracle Business Intelligence Answers". Also, it is strongly recommended that you go through this tutorial to know the steps involved in creating an Answers request, creating a dashboard page, and so on.
|
5. | Have set up the integration between BI Publisher, and Oracle BI EE: If you have included BI Publisher Enterprise, when you installed Oracle BI Enterprise Edition, Oracle BI installer will set up the integration with the Presentation Services, by setting host name, port, and URL values. However, you need to set the Administrator password from the BI Administration tool as follows:
If the integration with Presentation Services is not set up at the time of Oracle BI EE installation, you can also set up this integration from BI Publisher as follows:
|
6. | Have installed BI Publisher Desktop by clicking the Template Builder link in BI Publisher: When you install BI Publisher Desktop, it adds the BI Publisher menu in MS Word. |
7. | Have downloaded the Category Sales and Profits. rtf template file provided with this OBE from here . |
Note: All the seven steps listed above in the prerequisites are mandatory. Without performing this setup, you will not be able to proceed with the steps listed in the topics below. | |
8. | In addition to the above prerequisites, it is suggested that the learner go through the OBE "Creating a Repository using Oracle Business Intelligence Administration Tool " |
In this topic, you will connect to Oracle BI Presentation Services, open a pre-created BI Answers request, modify it as appropriate, and save it.
Follow the steps listed in each of the subtopics below:
Logging In to Oracle BI Presentation Services:
The interactive Web analytics components of Oracle BI EE, such as Oracle BI Interactive Dashboards, Oracle BI Answers, Oracle BI Delivers, Oracle BI Publisher, and Oracle BI Disconnected Analytics are collectively known asOracle BI Presentation Services. These components make it easy for users to gain complete and timely business insight and enable them to drive effective actions and processes.
Logging in to Presentation Services provides you access to all these components. To log in, perform the following steps:
1.
|
Select All Programs > Oracle Business Intelligence > Presentation Services from the Start menu (in Windows).
|
2.
| The Log In screen for Presentation Services appears. Enter Administrator as the User ID and Password, and click Log In. |
3. | The BI Interactive Dashboards page appears showing the sample dashboard created using the sales history reports. Click the Answers link to go to the BI Answers page. |
Opening and Modifying a BI Answers Request
In BI Answers, you can create a request from one of the subject areas listed on the BI Answers page, or create a request (SQL query) directed to the database. You can also open an existing request saved in folders. In this topic, you will open a pre-created request from the shared folder, and modify it to add more measures or fields.
1. | On the BI Answers page, observe the highlighted options in the screenshot below. Click the SH folder in theShared Folders section (displayed to the left) on the Catalog tabbed page. |
2. | This displays all the pre-created requests in the SH folder. Click the Category Sales for last 12 months link from the list of requests (displayed on the right). |
3. | You can see that the request is shown on the BI Answers page, which displays the chart. Click Modify to modify this request. |
4. | The request is displayed in the Edit mode, showing the Criteria tabbed page. To add more fields to the request, expand the nodes SH> Measures> Sales Facts and click Gross Profit to add this filed to the request. Similarly, also add the Amount Sold field to the request. (These measures that you have added should be reflected in the Criteria tab as shown in the screen below): |
5. | Click the Save Request icon (found on the top-right corner of the page) to save the changes you have made to the request. Enter the name of the request as "Category Sales and Profits for last 12 months" and click OK. |
In this topic, you connect to BI Publisher from MS Word and save the BI Answers request that you have modified in the previous topic as a BI Publisher report. You will also open a simple RTF file, and add graphs and table in the report template. You will also publish this template and view the data in the report.
Connecting to BI Publisher from MS Word to Save the Answers Request as BI Publisher Report
To create a BI Publisher report from the BI Answers request Category Sales and Profits for last 12 Months, perform the following steps:
1. | Start the MS Word application from the program menu. Open the Category Sales and Profits.rtf file (which is provided with this OBE). This is a simple rtf file with a header, footer, and a title as shown below: (Observe that the Oracle BI Publisher menu displayed in MS Word) From the Oracle BI Publisher menu, select Log On. Note: The Oracle BI Publisher menu is displayed in MS Word only when you have successfully installed the Oracle BI Publisher Desktop as mentioned in the step 6 of the Prerequisites section. Also, observe the BI Publisher tool bar in MS Word, with the Data, Insert, Preview , Tools, and Help menus. Observe the various options in these menus. |
2. | In the Login screen that appears, enter Administrator as the Username and Password, and click Login. The first time when you connect, you may be asked for the report server URL. Enter the URL in the following format: http://<Host>:9704/xmlpserver |
3. | This displays the Open Template window. Select Oracle BI from the Workspace drop-down list. Navigate to the shared>sh folder, and double click the Category Sales and Profits for last 12 Months BI Answers request that you modified and saved earlier. |
4. | This displays the Save As Oracle BI Publisher Report window. Navigate to the folder in which you want to save the report, and click Save. (Here the report is saved in MyFolders>Learn folder. You will then return to the rtf file in MS Word.) Hint: You can create a folder in BI Publisher (Web UI) by clicking the Create a New Folder link from the Folder and Report Tasks section. Do not close the rtf file that is open in MS Word or do not log off from BI Publisher to continue with the next topic. |
Creating a Layout with Charts and a Table For the BI Publisher Report
You have saved the Answers request as the BI Publisher Report in the previous topic. In this topic you will create a template for the report by adding a bar chart, a pie chart, and then a table to display the data. (Use the hints given in the Category Sales and Profits.rtf file to insert the charts and the table in appropriate places).
Follow the steps listed below to create a template for the report:
Follow the steps listed below to create a template for the report:
1. | In MS Word select Insert > Chart. (First, you will add a bar chart.) Note: When you save the Answer request as BI Publisher Report, its loads the XML data definitions into the RTF template file so that you can define the layout for the report data. |
2. | In the Chart window that appears, define the graph characteristics by following the instructions listed below carefully:
The bar graph in the template file looks like this: |
3. | Similarly, insert another Pie chart for showing the sales percentages by category. Follow the instructions listed steps below :
The pie chart in the template file looks like this: (Observe both the graphs): |
4. | Now select Insert > Table Wizard to define a format for the table data in the report. |
5. | This displays the Table Wizard. Select Table, and click Next. |
6. | Ensure that ROWSET/ROW is selected as the Grouping Field, and click Next. |
7. | Select Calendar. Calendar Month Desc, Calendar. Calendar Month Name, Products. Prod Category, Sales Facts. Amount Sold, and Sales Facts. Gross Profit from the list on the left, and add them to the list on the right. Click Next. See the screen given below: |
8. | Select Calendar. Calendar Month Desc from the Group By drop-down list, select Calendar. Calendar Month Name from the Then By drop-down list to group the data by calendar month. Accept the defaults for other options, and click Next. |
9. | In this step you can select the sort orders for various fields. Select Products. Prod Category from the Sort By drop-down list, accept the defaults for other options, and then click Next. |
10. | Edit the labels of the fields Products. Prod Category as Product Category, Sales Facts. Amount Sold as Sales Revenue, Sales Facts. Gross Profit as Profit. Then click Finish to complete the creation of the table template. The template file with the table you created looks like this: Important Note: The BI Publisher Desktop Template Builder has just created a table for you. Notice the words and letters with the gray background. These are called form fields. Form fields are Word objects that allow you to reference other data (for example, a mail merge letter). BI Publisher uses form fields in two ways:
|
11. | Now, you can additionally use the formatting features in MS Word on this template, such as changing the background and text colors, styles, adding an auto layout for the table, aligning the number fields to the right, and so on. Perform the following steps in MS Word:
Note: You can also use the Auto Format feature in MS Word to define a format for the table. To do this, select the table that you have added, and select Table > Table Auto Format menu option in MS Word. Select an auto format for the table from the list of available formats. |
12. | Also, to add an appropriate number format to the Sales Revenue field, double-click the_Sales_Facts.Amount_Sold_ field (highlighted in the screenshot) below the column header Sales Revenue. |
13. | This displays the Text Form Field Options for editing the formats. Select Number from the Type drop-down list. Enter the Default Number as 99,999,999.99, and select the format that has a $ in the beginning as shown, and click OK. Similarly, add an appropriate number format to the Profit column too. Now the table looks like this: |
14. | You can also add a form field to calculate the profit totals per month. Note: Add this total below the table, with an appropriate label such as Total Profit for the month of < Month name> is : <Profit Total>. Also align this entire label to the right so that it appears below the Profit column of the table. Click Insert> Field. (To insert the total in the place of the Profit Total in the above label) |
15. | In the Field window that appears, define the characteristics by following the instructions listed below carefully:
|
16. | Also add another field in place of <Month name> in the label:
Now the table along with the fields added looks like this:
Add appropriate colors to the Month name and Profit total fields (also add new lines where appropriate) so that the table looks like as shown below:
Save the rtf file in MS Word. You can add your initials to the file when saving. |
17. | You can also preview how the data in the report looks like. In MS Word, select Oracle BI Publisher> Preview Template> PDF to preview the data in PDF format. The charts and the data are shown in the screens below: Note: The header, footer, and other format changes you have defined in the template are reflected. You can also view the data in other formats such as HTML, RTF, and so on. Also, do not close the MS Word application or log out from BI Publisher to continue with the next topic. |
Publishing the Template for a BI Publisher Report
In the previous topic, you created a template for the BI Publisher report. In this topic, you publish the template created to view the report data in BI Publisher.
You can directly publish a template from MS Word to BI Publisher for a report, provided:
- You are connected to BI publisher from MS Word
- The BI Publisher report is opened in MS Word
- The template is saved in RTF format
Perform the following steps to publish the template created from MS Word, and then view data for the report in BI Publisher using this template: (Note that the template you have created satisfies all the above criteria.)
1. | In MS Word, select the Oracle BI Publisher > Publish Template As option. Note: If you have not saved the template in RTF format, it may prompt you to save the template in RTF format first before publishing. |
2. | The Upload as new dialog box appears. Enter Template1 as the template name, and click OK. After the template is uploaded, it displays the following message. Click OK again. |
Note: You can also view the data in the BI Publisher report using the template published, by connecting to BI Publisher (Web) as the Administrator. (Select All Programs > Oracle Business Intelligence > BI Publisher from the Start menu) Navigate to My Folders > Learn, and click the View link below the Category Sales and Profits for last 12 Monthsreport to view the data. The report is displayed using the template you have created. |
In this topic, you create a BI Dashboard page, and publish the BI Publisher report that you created from the BI Answers request on BI Interactive Dashboard. Perform the following steps:
1. | Log in to Oracle BI Presentation Services as Administrator (password Administrator). (Hint: Refer to the first topic for logging in to Presentation Services.) When you log in to Presentation Services, the BI Dashboards page is opened displaying the sample dashboard created with the sales trends as shown below: From the Page Options drop-down list (at the top-right corner of the page), select Edit Dashboard. |
2. | The Dashboard Editor page is displayed. Click the Add Dashboard Page icon to add a page to the dashboard. This displays the Add Dashboard Page screen. Enter My BI Publisher Page as the Page Name, and optionally enter a suitable description. Click OK. |
3. | Drag BI Publisher Report from the Dashboard Objects list to the section on the My BI Publisher Page as shown below: You can see that the BI Publisher Report object is added to the dashboard, click the Properties link on this object (highlighted in the screenshot). |
4. | The BI Publisher Report Properties screen is displayed. Click Browse to browse and specify the path for BI Publisher Report. |
5. | Select the Category Sales and Profits for last 12 Months report that you created earlier, from the path My Folders > Learn and click OK. |
6. | This brings you back to the BI Publisher Report Properties screen. In the Display Mode section of the report properties, select View the Latest Version option, accept defaults for other options, and then click OK. |
7. | This will take you back to the Dashboard Editor page, click Save to save the changes you made to the dashboard. |
8. | Click My BI Publisher Page tab to view the report that you published on this page: Scroll down to see the graphs and the entire report data in PDF format: |
In this topic, you will create a BI Publisher report from the BI Server Subject Area (Metadata). You will also create an RTF template in MS Word, and associate it with the report to view the data in BI Publisher.
Creating a BI Publisher Report from BI Server Subject Area
1. | Log in (if not logged in) to BI Publisher (Web) as Administrator (password Administrator). Note: You can log in to BI Publisher by logging in to Presentation Services and selecting More Products > BI Publisher option, or you can also log in to BI Publisher directly from: All Programs > Oracle Business Intelligence > BI Publisher option from the Start menu. The BI Publisher Welcome page is displayed: |
2. | Navigate to My Folders > Learn, and click Create a new report. Enter From BI Server as the name of the report, and click Create. |
3. | The newly created report is displayed in the BI Publisher. Click the Edit link displayed below the report name to edit the properties. |
4. | The report is displayed in edit mode. Click Data Model and click New to define the data source for this report. |
5. | On the Data Set page that appears, select SQL Query from the Type drop-down list. |
6. | On the Data Set page, select Cache Result. Ensure that Oracle BI EE is selected as the Data Source. (Observe the highlighted options in the screenshot.) Click Query Builder to create an SQL Query. |
7. | The Query Builder is opened displaying the SH subject area (metadata repository) objects displayed on the left. Drag the Channels, Products, and Sales Facts SH schema objects one by one to the Model canvas on the right. Hint: Take the help of the screens below: Drag Channels to the Model canvas. Similarly, drag Products and Sales Facts tables to the Model canvas. |
8. | Select the following columns to be displayed in the query from the Model objects (by selecting the check boxes beside the column names): -Select Channel Desc from Channels. -Select Prod Category and Prod Name from Products. -Select Amount Sold from Sales Facts. After the column selection, the Query Builder screen should look like this: |
9. | Click the Conditions link. In the Conditions screen, you can define the Aliases, Sorts, Group By fields, Conditions, and so on. Observe the options, and accept the defaults. |
10. | Click the Results link to see if the query results are displayed correctly without any error, and click Save to save the query. |
11. | This will take you back to the BI Publisher Data Set page. Observe that the query is displayed in the SQL Queryfield. Click the Save icon to save the report. Note: A simple SQL query is created here, but you can create more complex queries by defining Sorts, Aliases, Conditions, Group By fields, and so on in the Conditions screen of the Query Builder. Also, you can view the data after creating and publishing the template for this report. Now you can view only XML data for the report. (Click View to go to the View mode and click View again, if you want to view the XML data for the report). |
Creating an RTF Template in MS Word by Logging In to BI Publisher
1. | Start the MS Word application from the program menu. From the Oracle BI Publisher menu, select Log On. Enter Administrator as the username and password and click Login. |
2. | The Open Template window is displayed. Navigate and select the BI Publisher report that you have created from BI Server metadata from the path: My Folders > Learn > From BI Server, and click Open Report. (This will load the data from the query.) |
3. | In the Word document, select Insert > Chart to define a graph format for the SQL query data. |
4. | This opens the Chart window. Define the graph characteristics by following the instructions listed below carefully:
|
5. | The graph you defined for the SQL query data is displayed in the Word document as shown: (Observe the graph title that is displayed). |
6. | You can also add a table to represent the SQL query data. Select Insert > Table Wizard. In Table Wizard, select Table, and then click Next. |
7. | Ensure that ROWSET/ROW is selected as the Grouping Field, and click Next. |
8. | Click to include all the available fields in the table. (See the screenshot below.) Click Next. |
9. | Select Channel Desc from the Group By drop-down list; ensure that the Group above option is selected for this field. Select Prod Category from the Then By drop-down list, and select the Group left option for this field. Click Next. (Observe the highlighted options in the screenshot.) |
10. | Select Amount Sold from the Sort By drop-down list, select the Descending and Number options, and then clickNext. |
11. | Edit the labels for the fields: Change Prod Name to Product Name and Amount Sold to Sales Revenue. ClickFinish. The template that you have defined looks like this along with the table: |
12. | Make the appropriate format changes in MS Word to the table in the template: Guidelines to make changes: - Change the text colors to look similar to the colors used in the graph. - Change column widths of the table as appropriate. - Change Amount Sold field to a number field which is displayed in dollars ($). The table in the template looks like the following: (See the table highlighted in the screenshot.) |
13. | Save the template in RTF format as ProductSalesbyChannel_Templ.rtf. |
14. | You can also preview how the template looks like with the data in MS Word by selecting Oracle BI Publisher > Preview Template, and then selecting a format such as PDF to view the data. This helps you to preview, and make any further changes to the template before it is published. The PDF output in preview looks like this: |
Publishing the Template to View the Report Data in BI Publisher
Perform the following steps to publish the template created from MS Word for the BI Publisher report created from BI Server subject area, and then view data for the report in BI Publisher using this template:
1. | In MS Word, select the Oracle BI Publisher > Publish Template As option. Note: If you have not saved the template in RTF format, it may prompt you to save the template in RTF format first before publishing. |
2. | The Upload as new dialog box appears. Enter Template1 as the template name, and click OK. After the template is uploaded, it displays the following message. Click OK again. |
3. | ( If not already connected) Now connect to BI Publisher as Administrator. (Select All Programs > Oracle Business Intelligence > BI Publisher from the Start menu). Open the From BI Server report from My Folders > Learn. Note that the report is displayed using the template that you have created and published as shown in the following screenshot: Scroll down to see the table data (a portion of the data is shown below): You can also view the data in other formats such as PDF, RTF, MS Excel, and so on. Note: If you have time , and want to try more hands-on with BI Publisher, continue with the next topic of creating a report with parameters and list of values. |
In this topic, you will create a report with parameters and list of values using the From BI Server report you created in the previous topic.
Follow the steps listed below to create a report with parameters and list of values:
1. | (If not logged in) Log in to BI publisher as Administrator, and navigate to My Folders> Learn. Click the report icon beside the From BI Server report. |
2. | This displays additional report actions in the Report and Folder Tasks. Click Copy Report and then click Paste from Clipboard to paste it in the same folder. (See the screens below): Rename this copied report as From BI Server with Parameters and LOVs. Note: You can directly modify the From BI Server report to add parameters and LOVs too. |
3. | Now click the Edit link below the report to open the report in the Edit mode. Click New Data Set1 found under the Data Model node in the Report pane on the left to edit the SQL Query for the report. (Observe the screen below): |
4. | This displays the SQL Query for the report on the right. Edit the query to add a bind variable chname in the query as below: (observe the last line)
select Channels."Channel Desc" as "Channel Desc",
Products."Prod Category" as "Prod Category", Products."Prod Name" as "Prod Name", "Sales Facts"."Amount Sold" as "Amount Sold" from SH."Sales Facts" "Sales Facts", SH.Products Products, SH.Channels Channels where Channels."Channel Desc" = :chname
Click Save to save the query.
|
5. | Now click the Parameters node in the Report pane on the left and click New to create a parameter. |
6. |
This displays the Parameter screen on the right; define the following:
Enter chname as the name of the parameter, and select String as the Data Type.
Enter Internet in the Default Value field, and select Text as the Parameter Type. Also, type Enter a Channel Name: as the Display Label. (See the screen below).
Click Save to save the changes to the report.
|
7. |
Click View to view the report data using the existingTemplate1 in html format .
Note that the report data and graph are displayed with the default parameter value, that is for the Internet sales channel. |
8. |
You can enter the names of other channels to see the data.
For example, in the parameter field enter Partners as the channel name and click View again to see the data and graph for this channel: |
9. | Now click Edit to edit the report and define a List of Values to be used with this parameter chname. In the Report pane displayed on the left, click List of Values and click New to create a new list of values. |
10. | In the List of Values screen that appears on the right, ensure that Oracle BI EE is selected as the Data Source, and click Query Builder to define a query for defining a list of values. |
11. | In the Query Builder screen that displays the SH subject area on the left, click Channels to add it to the Modelcanvas on the right, and select Channel Desc column (by selecting the check box beside it). Click Save. This takes you back to the List of Values screen again which displays the query. Click Save to save the changes to report: |
12. | Now click chname found under the Parameters node in the Report pane on the left to edit it and associate it with the List of Values that you have created: |
13. | In the Parameter screen that appears on the right, now select Menu as the Parameter Type. In the Menu Setting section that appears below the General Settings section, enter Select a Channel Name: in the Display Label field, and ensure that the New List of Values 1 (that you created) is selected from the List of Values drop-down list. Also, select Can Select All option to be able to see the data for all the departments. Click Save to save the report. |
14. | Now click View to view the report using Template1 in HTML format. Observe that the chname parameter is now displayed using the list of values for the channels that you have defined: Note: You can select any of the channels from the drop-down list to view the data for that channel or select All to view the data for all channels. |
In this tutorial, you learned how to:
Create a BI Publisher report from BI Answers request | ||
Create a BI Publisher report from BI Server Subject Area | ||
Create RTF templates in MS Word by logging in to BI Publisher | ||
Publish the templates for a BI Publisher report | ||
View data in BI Publisher reports using the templates in various formats supported | ||
Create a report with parameters and list of values |