19 Configuring and Managing Analyses and Dashboards

This chapter describes how to configure and manage analyses and dashboards and the objects that they contain, such as views. For information on how content designers work with analyses and dashboards, see Oracle Fusion Middleware User's Guide for Oracle Business Intelligence Enterprise Edition.

End users with appropriate privileges can modify personal and shared dashboards, including the addition of pages and content. End users cannot create analyses and dashboards.

This chapter contains the following sections:

19.1 Managing Dashboards

Before you create shared dashboards, ensure that you have planned the Oracle BI Presentation Catalog directory or folder structure and security strategy. In general, to create a shared dashboard, you first create the dashboard and add content using the Dashboard Builder. You can also assign permissions to access the dashboard. Users who are members of multiple application roles or Catalog groups can select the dashboard that they display by default from all of the dashboards to which they have permissions.

The following list provides other resources with information on dashboards:

19.2 Performing General Configuration Tasks for Analyses

This section describes general tasks that you can perform to configure for the creation of analyses. It includes the following sections:

19.2.1 Providing Access to Metadata Dictionary Information

When creating analyses, content designers might need more information about subject areas, folders, columns, or levels (such as relationships to other metadata objects) to guide them. You can provide content designers with this information by allowing them access to the metadata dictionary for the repository. The metadata dictionary describes the metrics that are contained within the repository and the attributes of repository objects. The metadata dictionary output is a static set of XML documents.

To provide access to metadata dictionary information:

  1. Ensure that the metadata dictionary has been generated and the files have been stored in an appropriate location. For information about generating the metadata dictionary files, see Oracle Fusion Middleware Metadata Repository Builder's Guide for Oracle Business Intelligence Enterprise Edition.

  2. Set the DictionaryURLPrefix element within the ServerInstance element in the instanceconfig.xml file to one of the following values. The value that you specify depends on the Web servers in use.

    • The prefix for the name of the directory in which you have stored the XML files. The directory must have been specified as a shared directory for the Web server, and the Web server must be the same one that is used by Oracle BI EE.

      For example, suppose that you stored the XML files for the metadata dictionary in a directory called demo1 under the metadictionary directory. Suppose that the metadictionary directory is specified as a shared directory for the Web server, which is also used by Oracle BI EE. Then you specify the following value for the DictionaryURLPrefix element:

      <DictionaryURLPrefix>demo1/</DictionaryURLPrefix>

      See the documentation for your Web server for information on sharing directories.

    • The URL that points to the directory in which you have stored the XML files. Use a value such as this when the files for the metadata dictionary are stored in the directory structure for a Web server that is not being used by Oracle BI EE. For example:

      <DictionaryURLPrefix>http://10.10.10.10/metadictionary/demo1</DictionaryURLPrefix>

    The following shows an example setting in the instanceconfig.xml file:

    <WebConfig>
      <ServerInstance>
        <SubjectAreaMetadata>
          <DictionaryURLPrefix>demo1</DictionaryURLPrefix>
        </SubjectAreaMetadata>
      </ServerInstance>
    </WebConfig>
    

    For information about working in the Oracle BI Presentation Services configuration file (instanceconfig.xml), see Section 3.4, "Using a Text Editor to Update Oracle Business Intelligence Configuration Settings."

  3. Grant the Access to Metadata Dictionary privilege to the appropriate content designers. For information about privileges, see Section C.2.3.3, "Default Oracle BI Presentation Services Privilege Assignments."

For details on how content designers can view metadata dictionary information, see Oracle Fusion Middleware User's Guide for Oracle Business Intelligence Enterprise Edition.

19.2.2 Supporting Nested Folders, Navigation, and Drill Down

The Oracle BI Administrator can set up subject areas in ways that assist content designers who work with analyses. Oracle Fusion Middleware Metadata Repository Builder's Guide for Oracle Business Intelligence Enterprise Edition provides complete information on setting up subject areas. The following list describes the features of subject areas that assist content designers:

  • To make selections easy for content designers to discern in the Subject Areas pane when creating analyses, the administrator can set up the Presentation layer in the Oracle BI Administration Tool to give the appearance of nested folders. For example, the administrator can make the Sales Facts folder appear as a subfolder in the Facts folder.

  • When content designers create analyses, they can allow users to go to related analyses and content. If the Oracle BI Administrator sets up dimensions and dimensional hierarchies for the subject area, then users can drill down on data results that are presented in graphs, tables, and pivot tables to obtain more detailed information.

    There are no specific privilege settings that control access to navigation and drill down features, which are available to all users.

19.3 Configuring for Displaying and Processing Data in Views

You can configure various options that change the display and processing of data in views. See also Section 7.3.3, "Using Fusion Middleware Control to Set Configuration Options for Data in Tables and Pivot Tables" and Section 7.3.4, "Using Fusion Middleware Control to Set the Maximum Number of Rows Processed to Render a Table" for related information.

This section contains the following topics:

19.3.1 Manually Configuring for Data in Views

You can configure various options that change the processing and display of data in views, as described in the following sections:

19.3.1.1 Manually Configuring Cube Settings for Pivot Tables and Graphs

You can use settings within the Cube element to affect the display and processing of data in pivot tables and graphs. The settings also take effect for XMLA export.

Before you begin this procedure, ensure that you are familiar with the information in Section 3.4, "Using a Text Editor to Update Oracle Business Intelligence Configuration Settings".

To manually edit the Cube settings:

  1. Open the instanceconfig.xml file for editing, as described in Section 3.6, "Where are Configuration Files Located?"

  2. Locate the Cube section, in which you must add the following elements:

    • CubeMaxRecords — Specifies the maximum number of records that are returned by an analysis for the view to process. This roughly governs the maximum number of cells that can be populated in a view; unpopulated cells in a sparse view do not count. The default is 40000.

    • CubeMaxPopulatedCells — Specifies the maximum number of cells in a view that can be populated with data from the Oracle BI Server. The default is 120000.

  3. Include the elements and their ancestor elements as appropriate, as shown in the following example:

    <ServerInstance>
      <Views>
        <Cube>
          <CubeMaxRecords>30000</CubeMaxRecords>
          <CubeMaxPopulatedCells>120000</CubeMaxPopulatedCells>
        </Cube>
      </Views>
    </ServerInstance>
    
  4. Save your changes and close the file.

  5. Restart Oracle Business Intelligence.

19.3.1.2 Manually Configuring Settings for Data in Views

You can configure a similar group of settings that affects the display of data in tables, pivot tables, and graphs. While the settings are mainly the same, you must include the element within each appropriate parent element to override the default setting that applies to that view. For example, the views all use the MaxVisiblePages element. You must include that element within each of the Table, Pivot, and Charts parent elements, to override the default value of that setting for each of those view types.

Before you begin this procedure, ensure that you are familiar with the information in Section 3.4, "Using a Text Editor to Update Oracle Business Intelligence Configuration Settings".

To manually edit the settings that change the display of data in views:

  1. Open the instanceconfig.xml file for editing, as described in Section 3.6, "Where are Configuration Files Located?"

  2. Locate the Table, Pivot, and Charts parent sections, in which you must add the elements that are described in Table 19-1.

  3. Include the elements and their ancestor elements as appropriate, as shown in the following example.

    <ServerInstance>
      <Views>
          <Table>
            <MaxVisiblePages>1000</MaxVisiblePages>
            <MaxVisibleRows>500</MaxVisibleRows>
            <MaxVisibleSections>25</MaxVisibleSections>
            <DefaultRowsDisplayed>30</DefaultRowsDisplayed>
          </Table>
          <Pivot>
            <MaxVisibleColumns>300</MaxVisibleColumns>
            <MaxVisiblePages>1000</MaxVisiblePages>
            <MaxVisibleRows>500</MaxVisibleRows>
            <MaxVisibleSections>25</MaxVisibleSections>
            <DefaultRowsDisplayed>30</DefaultRowsDisplayed>
          </Pivot>
          <Charts>
            <MaxVisibleColumns>2000</MaxVisibleColumns>
            <MaxVisiblePages>1000</MaxVisiblePages>
            <MaxVisibleRows>2000</MaxVisibleRows>
            <MaxVisibleSections>25</MaxVisibleSections>
            <JavaHostReadLimitInKB>4096</JavaHostReadLimitInKB>
          </Charts>
      </Views>
    </ServerInstance>
    

    Note that this example does not include parameters that might exist in the file, but that are centrally managed by Fusion Middleware Control and cannot be changed manually.

  4. Save your changes and close the file.

  5. Restart Oracle Business Intelligence.

Table 19-1 describes the common elements that affect the display of data in views. If the user exceeds these values, then the Oracle BI Server returns an error message when the view is rendered.

Table 19-1 Common Elements for Manually Changing the Display of Data in Views

Element Description Default Value Applicable Views

DefaultRowsDisplayed

Specifies the default number of rows to display in the view.

30

Pivot Table, Table

MaxVisibleColumns

Specifies the maximum number of columns to be displayed in a view.

300

Graph, Pivot Table

MaxVisibleRows

Specifies the maximum number of rows to be displayed in a view.

For tables and pivot tables, specifies the number of rows that is displayed on the tooltip for the Display Maximum Rows per Page paging control button.

500

Graph, Pivot Table, Table

MaxVisiblePages

Specifies the maximum number of page choices (or pages in PDF) to be displayed in a view.

1000

Graph, Pivot Table, Table

MaxVisibleSections

Specifies the maximum number of sections to be displayed in a view.

This element does not apply when a slider is in place for a graph. The SectionSliderDefault and SectionSliderLimit elements apply to limit section values when a slider is in place. See Table 19-2.

25

Graph, Pivot Table, Table

JavaHostReadLimitInKB

Specifies the maximum amount of data that is sent to the browser for a single graph.

4096

Graph


19.3.2 Manually Configuring for Graphs and Gauges

You can configure various options that change the display of graphs, including funnel graphs, and gauges. These views types are also affected by the settings that are described in Section 19.3.1, "Manually Configuring for Data in Views."

Before you begin this procedure, ensure that you are familiar with the information in Section 3.4, "Using a Text Editor to Update Oracle Business Intelligence Configuration Settings".

To manually edit the settings that change the display of graphs and gauges:

  1. Open the instanceconfig.xml file for editing, as described in Section 3.6, "Where are Configuration Files Located?"

  2. Search for the Charts sections, in which you must add the elements that are described in Table 19-2.

  3. Include the elements and their ancestor elements as appropriate, as shown in the following example:

    <ServerInstance>
      <Views>
        <Charts>
         <EmbedFonts>True</EmbedFonts>
         <SectionSliderDefault>5</SectionSliderDefault>
         <SectionSliderLimit>10</SectionSliderLimit>
         <DefaultImageType>png</DefaultImageType>
         <FlashCodeBase>\\CORPORATE\Download\Flash</FlashCodeBase>
         <FlashCLSID>E38CDB6E-BA6D-21CF-96B8-432553540000</FlashCLSID>
        </Charts>
      </Views>
    </ServerInstance>
    
  4. Save your changes and close the file.

  5. Restart Oracle Business Intelligence.

Table 19-2 Elements for Configuring Graphs and Gauges

Element Description Default Value

EmbedFonts

See Section 19.3.2.1, "Configuring Fonts for Graphs" for details.

False

SectionSliderDefault

Specifies the default number of values that can be displayed on a section slider bar. A section slider displays members of one or more attribute or hierarchical columns as values on a rectangular bar and provides mechanisms to select a value.

For more information on defining section sliders in graphs and gauges, see Oracle Fusion Middleware User's Guide for Oracle Business Intelligence Enterprise Edition.

5

SectionSliderLimit

Specifies the maximum number of values that can be displayed on a section slider bar.

10

DefaultImageType

Specifies the image type to use when displaying a live graph as opposed to a static graph that is displayed in PDF files, during downloads and previews, and so on. The default is Flash.

The other choices are svg (W3C Scalable Vector Graphics) and png (W3C Portable Network Graphics). Ensure that you use lowercase letters when specifying the value.

Flash and SVG images provide the greatest degree of interaction because they support mouse-over behaviors (such as pop-up data labels), navigation, and drilling.

flash

FlashCodeBase

Specifies the name of the source for downloading the Flash plug-in. The default download source for the Flash plug-in is the vendor's Web site. In some organizations, users are instructed to download the latest Flash software from a corporate location instead of the vendor's Web site. You can modify the setting to point to another location that holds the Flash code base. Then, when users view a graph and a newer version of the Flash software is available on the corporate server, they can be prompted to download the newer version.

vendor's Web site

FlashCLSID

Specifies a custom global identifier (clsid) property for downloading Flash.

After modifying the Flash download directory using the FlashCodeBase element, you can enable a download prompt by creating a new classID for the Flash ActiveX control to add a custom global identifier property. You can obtain the current global identifier property from any computer where Oracle BI Presentation Services graphing is being used. (The global identifier property used by Oracle Business Intelligence is D27CDB6E-AE6D-11CF-96B8-444553540000.) The custom global identifier property must contain the same number of characters and dashes as the global identifier used in the default Flash ActiveX control.

You should test flash graphs independent of Oracle Business Intelligence to ensure that they function with the custom global identifier property.

NA


19.3.2.1 Configuring Fonts for Graphs

You can do one or both of the following tasks to configuring fonts for graphs:

  • Set the embed fonts element

  • Deliver font files for printing

19.3.2.1.1 Setting the Embed Fonts Element

By default, graphs rely on users to have the appropriate device fonts installed on their system to display multi-lingual text in the graphs. When users enable rotation on O1 axis labels, the graphs can look unattractive at certain angles. The labels appear obscured without any anti-aliasing. You can set the EmbedFonts element to True to specify the use of embedded fonts instead of device fonts, which resolves this display issue.

Be aware that the use of embedded fonts can cause a loss of fidelity. Whenever end users select fonts, they see the Oracle-licensed Albany WT plain fonts by default. Because the graphing engine does not provide embedded fonts for Chinese, Japanese, and Korean locales, users with those locales might obtain unattractive results for label rotation.

19.3.2.1.2 Delivering Font Files for Printing

If you plan to print graphs in bi-directional languages to PDF or graphs in Chinese, Japanese, or Korean to PNG images, then you must deliver required font files (.TTF) as follows:

  • To print graphs in bi-directional languages to PDF, you must deliver the Albany family of fonts to this Java Run-time Environment (JRE) directory:

    JAVA.HOME/lib/fonts

    where JAVA.HOME is the directory name as specified by the "java.home" system property.

  • To print graphs in Chinese, Japanese, or Korean to PNG images, you must deliver the font file that contains all the needed glyphs to this JRE directory:

    lib/fonts/fallback

For more information on font configuration files, see your Java documentation.

19.3.3 Manually Changing Alternating Bar Color

This section provides information on modifying message files to perform a specific task for views. For details on working with message files, including the directories that hold them, see Section 22.5, "Customizing the User Interface Using XML Message Files."

Both tables and pivot tables can have colored bars on alternating lines. Such formatting is sometimes called "green bar styling," and the default color for these alternating bars is green. For pivot tables, content designers can control formatting features when editing tables and pivot tables, including whether alternating bar color is enabled.

As the administrator, you can change the default color for alternating bars, by editing a style configuration file. To change the color, edit the views.css file in the b_mozilla_4 folder, as shown in the following list. Change the six-digit hexadecimal color value to a new color value.

  • Tables use the CSS selector:

    .ECell (for even-numbered rows)

    .OCell (for odd-numbered) rows.

  • Pivot tables use the CSS selector:

    .PTE (for odd-numbered rows)

The option for enabling the alternating bars is in the Edit View dialog and is labeled Enable alternating row "green bar" styling. If you change the color of the bars, then you might also want to change the label to indicate the color that you have set.

To change the label in the dialog for both the table and pivot table, open the tableviewmessages.xml file and find this entry:

WebMessageName = "kmsgTableViewEnableGreenbarReporting"

Copy the entry and the text line below it to a custom messages file in the custom messages folder, and change the text line appropriately. For example:

WebMessageName = "kmsgTableViewEnableGreenbarReporting"
<TEXT>Enable alternating row "RED bar" styling</TEXT>"

19.4 Manually Changing Presentation Settings

You can configure settings that change the display of dashboards and presentation settings, as described in the following sections:

19.4.1 Manually Changing Presentation Setting Defaults

In addition to the presentation settings that you can change in Fusion Middleware Control, other settings can be changed manually. Use various elements in the instanceconfig.xml file to change these settings.

Before you begin this procedure, ensure that you are familiar with the information in Section 3.4, "Using a Text Editor to Update Oracle Business Intelligence Configuration Settings".

To manually change additional presentation setting defaults:

  1. Open the instanceconfig.xml file for editing, as described in Section 3.6, "Where are Configuration Files Located?"

  2. Locate the sections in which you must add the elements that are described in Table 19-3.

  3. Include the elements and their ancestor elements as appropriate, as shown in the following example.

    <ServerInstance>
      <Dashboard>
        <DefaultName>Templates</DefaultName>
      </Dashboard>
      <Prompts>
          <MaxDropDownValues>50</MaxDropDownValues>
      </Prompts>
      <BriefingBook>
          <MaxFollowLinks>6</MaxFollowLinks>
      </BriefingBook>
    </ServerInstance>
    

    Note that this example does not include parameters that might exist in the file, but that are centrally managed by Fusion Middleware Control and cannot be changed manually.

  4. Save your changes and close the file.

  5. Restart Oracle Business Intelligence.

  6. See Section 19.4.2, "Configuring Links to Dashboard Pages" for information on the Bookmarks, MaxAgeMinutes, EnableBookmarkURL, and EnablePromptedURL elements.

  7. See Section 19.4.3, "Configuring an Alternate Toolbar for Oracle BI Publisher" for information on the ReportingToolbarMode element.

Table 19-3 Elements for Manually Changing Additional Presentation Setting Defaults

Element Description Default Value

DefaultName

Specifies the name to be used for dashboards that contain dashboard template pages and to override the path in which Oracle BI EE searches for dashboard template pages. By default, Oracle BI EE searches for dashboard template pages in dashboards named "default" in subfolders under /Shared Folders.

default

MaxDropDownValues

Specifies the maximum number of choices to display in the following locations:

  • In choice lists in dashboard prompts.

  • In the Available list of the Select Values dialog that is displayed when you click the Search link in a prompt. Click the More link to display additional choices.

  • In the Available list of the Select Values dialog when you perform a search in that dialog.

For information about prompts and searching, see Oracle Fusion Middleware User's Guide for Oracle Business Intelligence Enterprise Edition.

256

MaxFollowLinks

Specifies the default value for the maximum number of navigation links to follow in a briefing book. A briefing book navigation link is a type of link that can be added to a dashboard using the Dashboard Builder.

The default value for this element is 5; the minimum is 1; and the maximum is 10.

If you plan to download briefing books to PDF format, then do not set the value of this element to a number greater than 9 because of the table of contents limitation of nine links. For information about the table of contents, see Section 19.4.4, "Modifying the Table of Contents for PDF Versions of Briefing Books."

For information about working with briefing books, see Oracle Fusion Middleware User's Guide for Oracle Business Intelligence Enterprise Edition.

5


19.4.2 Configuring Links to Dashboard Pages

Users can create links to dashboard pages. This allows them, for example, to save a link as a bookmark or to copy and send a link to other users in e-mail. A bookmark is a hidden object in the Oracle BI Presentation Catalog (under the /system/bookmarks folder) that captures the state of a dashboard page. It is created when a user creates a bookmark link to the page. You can use the following elements to configure the creation of these links:

  • EnableBookmarkURL: Use this element to specify whether to show the Create Bookmark Link option on the Page Options menu, which allows users to create bookmark links to dashboard pages:

    • True — Shows the Create Bookmark Link option. (Default)

      If drilling in an analysis that has been set to replace a dashboard with the new results (rather than show the new results directly in the dashboard), then the Create Bookmark Link is displayed as a link below the new results rather than as an option on the Page Options menu.

    • False — Does not show the Create Bookmark Link option.

  • EnablePromptedURL: Use this element to specify whether to show the Create Prompted Link option on the Page Options menu, which allows users to create prompted links to dashboard pages:

    • True — Shows the Create Prompted Link option. (Default)

    • False — Does not show the Create Prompted Link option.

  • MaxAgeMinutes: Use this element within the Bookmarks element to specify that bookmarks older than the specified number of minutes are removed. The default is 43200 minutes, which corresponds to 30 days.

    Note that every time a bookmark is accessed, the expiration timer is reset. This resetting means that if a bookmark is accessed frequently, it might never be removed. Setting the value to 0 means that the bookmark is saved for 0 minutes (and does not mean that it does not expire). You cannot set bookmarks to never expire. If you want bookmarks to last for a long time, then set the value to a large number of minutes and access the bookmarks within the allotted number of minutes.

The following entry is an example of these settings:

<ServerInstance>
  <Dashboard>
    <EnableBookmarkURL>true</EnableBookmarkURL>
    <EnablePromptedURL>true</EnablePromptedURL>
  </Dashboard>
  <Cache>
      <Bookmarks>
          <MaxAgeMinutes>43200</MaxAgeMinutes>
      </Bookmarks>
  </Cache>
</ServerInstance>

19.4.3 Configuring an Alternate Toolbar for Oracle BI Publisher

When you include a BI Publisher report on a dashboard, you generally allow that report to participate as a recipient of the dashboard state by passing in dashboard context to that report using core dashboard prompts. For scenarios that do not require passing of context to or from the BI Publisher report to the larger dashboard-based analytic application, you can display a variant of the default BI Publisher toolbar, which exposes the underlying parameter prompts of that BI Publisher report. Within that frame, a user can then pass in parameters to a single BI Publisher report.

This approach can be confusing to the user as any other dashboard prompts on the page do not contribute to the BI Publisher report, which also does not participate in passing context back to the rest of the application. Changes to the BI Publisher toolbar are also applied globally for all BI Publisher reports that are embedded in dashboards across the entire Presentation Services instance.

Use the ReportingToolbarMode element to affect how BI Publisher reports are embedded in Oracle BI EE. You configure the alternate BI Publisher toolbar by setting the element's value to 6. Remove the ReportingToolbarMode element to revert to the default toolbar behavior, or set it to the default value of 1.

Before you begin this procedure, ensure that you are familiar with the information in Section 3.4, "Using a Text Editor to Update Oracle Business Intelligence Configuration Settings".

To manually configure an alternate toolbar for BI Publisher:

  1. Open the instanceconfig.xml file for editing, as described in Section 3.6, "Where are Configuration Files Located?"

  2. Locate the AdvancedReporting section in which you must add the ReportingToolbarMode element.

  3. Include the element and its ancestor elements as appropriate, as shown in the following example.

    <ServerInstance>
      <AdvancedReporting>
          <ReportingToolbarMode>6</ReportingToolbarMode>
      </AdvancedReporting>
    </ServerInstance>
    

    The following list describes the element values:

    • 1 = Does not display the toolbar.

    • 2 = Displays the URL to the report without the logo, toolbar, tabs, or navigation path.

    • 3 = Displays the URL to the report without the header or any parameter selections. Controls such as Template Selection, View, Export, and Send are still available.

    • 4 = Displays the URL to the report only. No other page information or options are displayed.

    • 6 = Displays the BI Publisher toolbar to display the parameter prompts of the BI Publisher report

  4. Save your changes and close the file.

  5. Restart Oracle Business Intelligence.

19.4.4 Modifying the Table of Contents for PDF Versions of Briefing Books

The PDF version of a briefing book contains a table of contents that is automatically generated. It contains an entry for each dashboard page, analysis, and report in the briefing book. See Oracle Fusion Middleware User's Guide for Oracle Business Intelligence Enterprise Edition for information on the table of contents.

The default template for the table of contents, toc-template.rtf, is located in the ORACLE_INSTANCE\config\OracleBIPresentationServicesComponent\coreapplication_obisn directory. You can modify the toc-template.rtf file to accommodate the needs of your organization.

19.5 Controlling Access to Saved Customization Options in Dashboards

This section provides an overview of saved customizations and information about administering saved customizations. It contains the following topics:

19.5.1 Overview of Saved Customizations in Dashboards

Saved customizations allow users to save and view later dashboard pages in their current state with their most frequently used or favorite choices for items such as filters, prompts, column sorts, drills in analyses, and section expansion and collapse. By saving customizations, users need not make these choices manually each time that they access the dashboard page.

Users and groups with the appropriate permissions and dashboard access rights can perform the following activities:

  • Save various combinations of choices as saved customizations, for their personal use or use by others.

  • Specify a saved customization as the default customization for a dashboard page, for their personal use or use by others.

  • Switch between their saved customizations.

You can restrict this behavior in the following ways:

  • Users can view only the saved customizations that are assigned to them.

  • Users can save customizations for personal use only.

  • Users can save customizations for personal use and for use by others.

For information about end users and saved customizations with dashboards, see Oracle Fusion Middleware User's Guide for Oracle Business Intelligence Enterprise Edition.

19.5.2 Administering Saved Customizations

This section describes the privileges and permissions that are required to administer saved customizations. It also describes the relevant portions of the Oracle BI Presentation Catalog that relate to storing and administering saved customizations.

19.5.2.1 Privileges for Saved Customizations

In Oracle BI Presentation Services Administration, the following privileges in the Dashboards area, along with permission settings for key dashboard elements, control whether users or groups can save or assign customizations:

  • Save Customizations

  • Assign Default Customizations

You can set neither privilege, one privilege, or both privileges for a user or group, depending on the level of access desired. For example, a user who has neither privilege can view only the saved customization that is assigned as his or her default customization.

19.5.2.2 Permissions for Saved Customizations

This section describes the permissions that are required for users to administer saved customizations of dashboard pages, and the relevant portions of the Oracle BI Presentation Catalog structure for setting permissions on shared and personal saved customizations.

19.5.2.2.1 Assigning Permissions to Dashboards

You set permissions for dashboards and pages, such as Full Control or No Access, in the Permission dialog in Oracle BI EE. You assign these permissions in the same manner as for other objects in the catalog.

19.5.2.2.2 Assigning Permissions for Customizations on a Dashboard Page

You set permissions for working with saved customizations on a particular dashboard page in the Dashboard Properties dialog, which is available in the Dashboard Builder. After selecting a page in the list in the dialog, click one of the following buttons:

  • Specify Who Can Save Shared Customizations displays the Permission dialog in which you specify who can save shared customizations for that dashboard page.

  • Specify Who Can Assign Default Customizations displays the Permission dialog in which you specify who can assign default customizations for that dashboard page.

Catalog objects and permissions scenarios are described in the following sections.

19.5.2.2.3 Catalog Folder Structure for Saved Customizations

In addition to the privileges that you set in Oracle BI Presentation Services Administration, the level of control that users and groups have over saved customizations depends on their access rights to key elements. For example, users and groups that can create and edit underlying dashboards, save dashboard view preferences as customizations, and assign customizations to other users as default customizations require Full Control permission to the key elements in shared storage, while users and groups that can view only their assigned default saved customizations need only View access to the key elements in shared storage.

Key elements in the catalog include the following folders:

  • Shared Storage Folders.

    Shared storage folders for dashboards are typically located within the Dashboards sub-folder of a parent shared folder. Dashboards are identified by their assigned names. You can save a dashboard anywhere in the Oracle BI Presentation Catalog. If you save a dashboard within a subfolder called "Dashboards", then that dashboard's name is displayed in the list of dashboards that is displayed from the Dashboards link in the global header.

    Permission settings control access to a specific dashboard for editing. Typically, if permissions are inherited down to the _selections and Dashboards sub-folders, then users who can edit dashboards can also save customizations and set defaults. Access to a specific dashboard folder controls whether a user or group can edit the dashboard.

    The _selections folder contains a page identifier folder for each dashboard page. Shared saved customizations are located within this folder. Access to the page identifier folder controls whether a user or group can display, save, or edit customizations for that page.

    The _defaults folder within a _selections folder contains assigned default customizations. Each group that has an assigned default is displayed here. Access to this folder controls whether a user or group can assign defaults.

  • Personal Storage Folders.

    Within a user's personal folder, the _selections folder contains an individual user's saved customizations. Like the shared _selections folder, a personal _selections folder contains a page identifier folder for each dashboard page. The page identifier folder contains personal saved customizations and a _defaultlink file that specifies a user's preference for the personal defaulted customization.

    A personal saved customization default overrides an assigned shared customization default.

    Note:

    If a dashboard page with saved customizations is deleted, then the saved customizations are also deleted from the catalog. If the underlying dashboard structure changes such that a saved customization is no longer valid when a user accesses it, then the default content is displayed on the dashboard.

19.5.3 Permission and Privilege Settings for Creating Saved Customizations

Table 19-4 describes typical user roles and specific permission settings that can be granted to users for creating saved customizations. The folder names listed in the Permission and Privilege Settings column are described in the preceding section.

Table 19-4 User Roles and Permission Settings for Saved Customizations

User Role Permission and Privilege Settings

Power users such as IT users who must perform the following tasks:

  • Create and edit underlying dashboards.

  • Save dashboard view preferences as customizations.

  • Assign customizations to other users as default customizations.

In the Shared section of the catalog, requires Full Control permission to the following folders:

  • dashboard_name

  • _selection

  • _defaults

Typically, no additional privileges must be assigned.

Technical users such as managers who must perform the following tasks:

  • Save customizations as customizations for personal use.

  • Save customizations for use by others.

Users cannot create or edit underlying dashboards, or assign view customizations to others as default customizations.

In the Shared section of the catalog, requires View permission to the following folders:

  • dashboard_name

In the Shared section of the catalog, requires Modify permission to the following folders:

  • _selections

  • _defaults

Typically, no additional privileges must be assigned.

Everyday users who must save customizations for personal use only.

In Oracle BI Presentation Services Administration, requires the following privilege to be set:

  • Save Customizations

In the dashboard page, requires that the following option is set:

  • Allow Saving Personal Customizations

In the catalog, no additional permission settings are typically required.

Casual users who must view only their assigned default customization.

In the Shared section of the catalog, the user needs View permission to the following folders:

  • dashboard_name

  • _selections

  • _defaults

In the catalog, no additional permission settings are typically required.


19.5.4 Example Usage Scenario for Saved Customization Administration

Depending on the privileges set and the permissions granted, you can achieve various combinations of user and group rights for creating, assigning, and using saved customizations.

For example, suppose a group of power users cannot change dashboards in a production environment, but they are allowed to create saved customizations and assign them to other users as default customizations. The following permission settings for the group are required:

  • Open access to the dashboard, using the Catalog page.

  • Modify access to the _selections and _defaults subfolders within the dashboard folder in the Oracle BI Presentation Catalog, which you assign using the Dashboard Properties dialog in the Dashboard Builder. After selecting a page in the list in the dialog, click Specify Who Can Save Shared Customizations and Specify Who Can Assign Default Customizations.

19.6 Blocking Analyses in Answers

You might want to block specific analyses, such as requiring content designers to include certain columns with others, or requiring filters when certain columns are requested. Answers includes an API that you can use to block queries based on the criteria specified in the analysis or based on formulas in the analysis. You can access the API using JavaScript to check conditions and validate analyses.

This section contains the following topics:

19.6.1 Storing JavaScript Files

This section explains how to use JavaScript to check conditions and validate analyses. You write your own JavaScript programs for performing these tasks and other similar ones. Oracle BI EE does not install any JavaScript programs. As you write JavaScript programs, you can store them in the following directory:

ORACLE_INSTANCE\bifoundation\OracleBIPresentationServicesComponent\coreapplication_obipsn\analyticsRes

To place JavaScript programs in a directory other than this one, then you can do so, if you specify the full path name in the code that calls the program. For example, you can use code such as the following:

<script type="text/javascript" src="http://example/mydir/myblocking.js" />

19.6.2 Blocking Analyses Based on Criteria

When a user attempts to execute an analysis that your code blocks, you can display an error message, and the analysis is not executed. The answerstemplates.xml file includes a message named kuiCriteriaBlockingScript that can be overridden to either define or include JavaScript that defines a validateAnalysisCriteria function. By default, this message contains a function that always returns True. It should be overridden using the procedures that are described in Section 22.4, "Customizing Language Selections and Other Components."

Answers calls your validateAnalysisCriteria function when the user tries to execute the analysis. The function can return True if the analysis is not blocked, or False, or a message if the analysis is blocked. If a message or a value other than False is returned, then the message is displayed in a popup window. In either case, the query is blocked.

The following code example shows the blocking of a query. First, place the following XML code in the answerstemplates.xml file.

<?xml version="1.0" encoding="utf-8"?>
<WebMessageTables xmlns:sawm="com.siebel.analytics.web.messageSystem">
   <WebMessageTable system="QueryBlocking" table="Messages">
   <WebMessage name="kuiCriteriaBlockingScript" translate="no">
      <HTML>
         <script type="text/javascript" src="fmap:myblocking.js" />
      </HTML>
   </WebMessage>
   </WebMessageTable>
</WebMessageTables>

This XML code calls a JavaScript program called myblocking.js. Ensure that you place this file in the ORACLE_INSTANCE\bifoundation\OracleBIPresentationServicesComponent\coreapplication_obipsn\analyticsRes directory. The following is sample code for the myblocking.js program.

// This is a blocking function. It makes sure users pick what I want them to.
function validateAnalysisCriteria(analysisXml)
{
   // Create the helper object
   var tValidator = new CriteriaValidator(analysisXml);
   // Validation Logic
   if (tValidator.getSubjectArea() != "Paint")
      return "Why don't you try Paint?";
   if (!tValidator.dependentColumnExists("Markets","Region","Markets","District"))
   {
      // If validation script notifies user, then return false
      alert("Region and District go so well together, do you think?");
      return false;
   }
   if (!tValidator.dependentColumnExists("Sales Measures","","Periods","Year"))
   return "You picked a measure so pick Year!";
   if (!tValidator.filterExists("Sales Measures","Dollars"))
   return "Maybe filter on Dollars?";
   if (!tValidator.dependentFilterExists("Markets","Market","Markets"))
   return "Since you're showing specific Markets, filter the markets.";
   var n = tValidator.filterCount("Markets","Region");
   if ((n <= 0) || (n > 3))
      return "Select 3 or fewer specific Regions";
   return true;
}

If you do not override the function using the template as described previously, or if the function returns anything other than False, then the criteria is considered to be valid and the analysis is issued. The criteria is validated using this same mechanism for preview and save operations as well.

After making this change, either stop and restart the server for Oracle BI Presentation Services, or click the Reload Files and Metadata link on the Administration page.

19.6.3 Blocking Analyses Based on Formula

Answers provides a hook that lets you incorporate a JavaScript validation function that is called from Answers when a content designer enters or modifies a column formula. If the call fails and returns a message, then Answers displays the message and cancels the operation. Additionally, helper functions are available so the query blocking function can check for filters, columns, and so on, rather than traversing the Document Object Model (DOM) manually. (The DOM is a way of describing the internal browser representation of the HTML UI page that is currently being displayed in Answers.) For more information on the helper functions, see Section 19.6.4, "Validation Helper Functions."

The criteriatemplates.xml file includes a message named kuiFormulaBlockingScript that can be overridden to include JavaScript that defines a validateAnalysisFormula function. By default, this message contains a function that always returns True.

Answers calls validateAnalysisFormula before applying changes made by the content designer. If the function returns True, then the formula is accepted. If the function returns False, then the formula is rejected. Otherwise, the return value from the function is displayed in the message area beneath the formula, as it does currently when an invalid formula is entered.

The content designer has the option to click OK to ignore the error. To display your own alert and allow the content designer to continue, your function should return True. To block the query, return False or a message. Your function should investigate the formula passed to it using a JavaScript string and regular expression techniques for validation.

The following code example shows a sample custom message.

<?xml version="1.0" encoding="utf-8"?>
<WebMessageTables xmlns:sawm="com.siebel.analytics.web.messageSystem">
   <WebMessageTable system="QueryBlocking" table="Messages">
      <WebMessage name="kuiFormulaBlockingScript" translate="no">
         <HTML>
            <script type="text/javascript" src="fmap:myblocking.js" />
         </HTML>
      </WebMessage>
   </WebMessageTable>
</WebMessageTables>

The following code example shows blocking based on the formula entered.

// This is a formula blocking function. It makes sure the user does not enter an unacceptable formula.
function validateAnalysisFormula(sFormula, sAggRule)
{
   // we do not allow the use of concat || in our formulas
   var concatRe = /\|\|/gi;
   var nConcat = sFormula.search(concatRe);
   if (nConcat >= 0)
      return "You used concatenation (character position " + nConcat + "). That is not allowed.";
   // no case statements
   var caseRe = /CASE.+END/gi;
   if (sFormula.search(caseRe) >= 0)
      return "Do not use a case statement.";
   // Check for a function syntax: aggrule(formula) aggrule should not contain a '.'
   var castRe = /^\s*\w+\s*\(.+\)\s*$/gi;
   if (sFormula.search(castRe) >= 0)
      return "Do not use a function syntax such as RANK() or SUM().";
    return true;
}

After making this change, either stop and restart the server for Oracle BI Presentation Services, or click the Reload Files and Metadata link on the Administration page.

19.6.4 Validation Helper Functions

These functions are defined within a JavaScript file named answers/queryblocking.js. Table 19-5 contains the list of helper functions and their descriptions.

Table 19-5 Validation Helper Functions

Validation Helper Function Description

CriteriaValidator.getSubjectArea()

Returns the name of the subject area referenced by the analysis. It generally is used in a switch statement within the function before doing other validation. If the analysis is a set-based criteria, then it returns null.

CriteriaValidator.tableExists(sTable)

Returns True if the specified folder (table) has been added to the analysis by the content designer, and False if the folder was not added.

CriteriaValidator.columnExists(sTable, sColumn)

Returns True if the specified column has been added to the analysis by the content designer, and False if the column was not added.

CriteriaValidator.dependentColumnExists(sCheckTable, sCheckColumn, sDependentTable, sDependentColumn)

Checks to ensure that the dependentColumn exists if the checkColumn is present. It returns True if either the checkColumn is not present, or the checkColumn and the dependent column are present. If checkColumn and dependentColumn are null, then the folders are validated. If any column from checkTable is present, then a column from dependentTable must be present.

CriteriaValidator.filterExists(sFilterTable, sFilterColumn)

Returns True if a filter exists on the specified column, and False if no filter is present.

CriteriaValidator.dependentFilterExists(sCheckTable, sCheckColumn, sFilterTable, sFilterColumn)

Checks to ensure that the dependentFilter exists if the checkColumn is present in the projection list. It returns True if either the checkColumn is not present, or the checkColumn and the dependent filter are present.

CriteriaValidator.filterCount(sFilterTable, sFilterColumn)

Returns the number of filter values that are specified for the given logical column. If the filter value is "equals," "null," "notNull," or "in," then it returns the number of values chosen. If the column is not used in a filter, then it returns zero. If the column is prompted with no default, then it returns -1. For all other filter operators (such as "greater than," "begins with," and so on) it returns 999, because the number of values cannot be determined.


19.7 Specifying View Defaults for Analyses and Dashboards

You can control certain aspects of the initial state of new views that are added to an analysis and of new objects that are added to a dashboard page. For example, you can add a default footer to new analyses and set defaults for dashboard sections. You control these aspects by customizing the appropriate XML message files to override the default values that are specified during installation.

19.7.1 XML Message Files for View Defaults

This section describes the XML message files to customize to override the view defaults distributed with Oracle BI Presentation Services.

For analyses, the file answerstemplates.xml includes a message named kuiCriteriaDefaultViewElementsWrapper from within kuiAnswersReportPageEditorHead. This message includes two additional messages, kuiCriteriaDefaultViewElements, in which you can define default values, and kuiCriteriaDefaultViewElementsMask, in which masks are defined. The mask XML message is protected and you cannot modify its contents.

The wrapper message adds the combined XML into a JavaScript variable, kuiDefaultViewElementsXML, that is used to apply the new default values.

For dashboards, the file dashboardtemplates.xml includes a message named kuiDashboardDefaultElementsWrapper that adds XML into a JavaScript variable named kuiDefaultDashboardElementsXML for use within the dashboard editor.

Note:

For information about the core tasks that are required to customize XML message files, see Section 22.5, "Customizing the User Interface Using XML Message Files." The examples in this section assume that you are familiar with this information.

19.7.2 Examples of Customizing Default Values for Analyses and Dashboards

The following sections provide examples of customizing default values:

To cause these customizations to take effect, either stop and restart the server for Oracle BI Presentation Services, or click the Reload Files and Metadata link on the Administration page.

19.7.2.1 Adding a Default Header or Footer to New Analyses

You can specify that default headers and footers are displayed on all new analyses. For example, footers can contain messages such as a confidentiality notice, the company's name, and so on. You can specify a default header or footer by creating an XML message that specifies the text and formatting to apply.

The following XML code example creates a footer that contains the text "Acme Confidential" in bold, red letters.

<?xml version="1.0" encoding="utf-8"?>
<WebMessageTables xmlns:sawm="com.siebel.analytics.web.messageSystem">
   <WebMessageTable system="Answers" table="ViewDefaults">
<WebMessage name="kuiCriteriaDefaultViewElements" translate="no"><HTML>
   <view signature="compoundView" >
      <pageProps pageSize="a4">
         <pageFooter showOnDashboard="true" show="true">
            <zone type="top"><caption>[b]Acme Confidential[/b]</caption>
            <displayFormat fontColor="#FF0000"/></zone>
         </pageFooter>
      </pageProps>
   </view>
</HTML>
</WebMessage>
   </WebMessageTable>
</WebMessageTables>

19.7.2.2 Preventing Auto-Previewing of Results

The results of an analysis are displayed when editing views of data. If you prefer that the content designer explicitly asks to view the results, then you can create an XML message that specifies that auto-preview should be disabled when new views are created. The content designer can still click the Display Results link to view the results when editing a view.

The following XML code example disallows the auto-previewing of results when working with a view in Answers.

<?xml version="1.0" encoding="utf-8"?>
<WebMessageTables xmlns:sawm="com.siebel.analytics.web.messageSystem">
   <WebMessageTable system="Answers" table="ViewDefaults">
<WebMessage name="kuiCriteriaDefaultViewElements" translate="no"><HTML>
   <view signature="tableView" showToolBar="true" showHeading="true />
   <view signature="pivotTableView" autoPreview="false" />
   <view signature="titleView" autoPreview="false" />
   <view signature="viewSelector" autoPreview="false" />
   <view signature="htmlviewnarrativeView" autoPreview="false" />
   <view signature="tickerview" autoPreview="false" />
   <view signature="htmlview" autoPreview="false" />
</HTML>
</WebMessage>
   </WebMessageTable>
</WebMessageTables>

19.7.2.3 Setting Defaults for Analyses in the Compound Layout

The results of a newly formed analysis are displayed as a title view followed by either a table or pivot table in a compound layout. A table is created if the analysis contains only attribute columns, and a pivot table is created if the analysis contains at least one hierarchical column.

You can create an XML message that specifies that the compound view should default to a different assemblage of views, such as a narrative followed by a graph. The content designer can still add and rearrange views within the compound layout.

The following XML code example sets the default compound layout to a narrative followed by a graph.

<?xml version="1.0" encoding="utf-8"?>
<WebMessageTables xmlns:sawm="com.siebel.analytics.web.messageSystem">
   <WebMessageTable system="Answers" table="ViewDefaults">
<WebMessage name="kuiCriteriaDefaultViewElements" translate="no"><HTML>
   <view signature="compoundView" >
      <cv signature="narrativeView" />
      <cv signature="dvtchart" />
   </view>
</HTML>
</WebMessage>
   </WebMessageTable>
</WebMessageTables>

19.7.2.4 Changing Dashboards Section Defaults

By default, the results of drilling in a dashboard are displayed on a new page, section names are not displayed in the dashboard, and sections can be expanded and collapsed. You can change these default values by creating an XML message that specifies that new default values for the dashboard section. A content designer who edits the dashboard can still modify this behavior using the options within the dashboard editor.

The following XML code example makes section heads visible, enables drilling, and does not allow sections to collapse.

<?xml version="1.0" encoding="utf-8"?>
<WebMessageTables xmlns:sawm="com.siebel.analytics.web.messageSystem">
   <WebMessageTable system="Answers" table="ViewDefaults">
<WebMessage name="kuiDashboardDefaultElements" translate="no"><HTML>
   <element signature="dashboardSection" drillInline="true" showHeading="true" collapsible="false" />
</HTML>
</WebMessage>
   </WebMessageTable>
</WebMessageTables>

19.7.2.5 Specifying Dashboard Page Defaults Including Headers and Footers

By default, dashboards are printed without headers or footers and in a portrait orientation. If you prefer that newly added dashboard pages default to having a custom header and footer and print in landscape orientation, then you can create an XML message that specifies these characteristics. A content designer who edits the dashboard can still modify this behavior using the options within the dashboard editor.

The following XML code example adds a custom header and footer to a dashboard page and specifies landscape orientation.

<?xml version="1.0" encoding="utf-8"?>
<WebMessageTables xmlns:sawm="com.siebel.analytics.web.messageSystem">
   <WebMessageTable system="Answers" table="ViewDefaults">
<WebMessage name="kuiDashboardDefaultElements" translate="no"><HTML>
<element signature="dashboardPage" personalSelections="false">
     <pageProps orientation="portrait" printRows="all" pageSize="a4">
         <pageHeader showOnDashboard="true" show="true">
            <zone type="top"><caption>[b]Acme is Cool[/b]</caption>
            <displayFormat fontSize="9pt" hAlign="center"
fontColor="#FFFFFF" backgroundColor="#000000"/></zone>
         </pageHeader>
         <pageFooter showOnDashboard="true" show="true">
            <zone type="top"><caption>[b]CONFIDENTIAL
@{timeCreated[mm/dd/yy]}[/b]</caption>
            <displayFormat fontSize="7.5pt" hAlign="center"
fontColor="#999999" borderColor="#CC99CC" fontStyle="italic"
borderPosition="all" borderStyle="single"/></zone>
         </pageFooter>
       </pageProps>
   </element>
</HTML>
</WebMessage>
   </WebMessageTable>
  </WebMessageTables>

19.7.2.6 Including Links with Analyses on Dashboards

By default, the results of embedded analyses are displayed within the dashboard without including any links. If you prefer that newly added analyses default to having Edit and Refresh links, for example, then you can create an XML message that specifies that the analysis should behave this way. A content designer who edits the dashboard can still modify this behavior using the options within the Dashboard Builder.

In the XML message file, the links attribute can contain any combination of the letters c, d, e, f, g, m, and r to add the indicated link, as shown in the following list that provides the letter and corresponding link name:

  • c = Copy

  • d = Export

  • e = Edit

  • f = Print

  • g = Add to Briefing Book

  • m = Analyze

  • r = Refresh

The following XML code example adds Edit and Refresh links to new analyses embedded in dashboards.

<?xml version="1.0" encoding="utf-8"?>
<WebMessageTables xmlns:sawm="com.siebel.analytics.web.messageSystem">
   <WebMessageTable system="Answers" table="ViewDefaults">
<WebMessage name="kuiDashboardDefaultElements" translate="no"><HTML>
   <element signature="reportView" display="embed" links="er" />
</HTML>
</WebMessage>
   </WebMessageTable>
</WebMessageTables>

19.8 Configuring for Write Back in Analyses and Dashboards

Users of a dashboard page or an analysis might have the ability to modify the data that they see in a table view. This ability is often referred to as "write back." As the administrator, you assist the content designer in configuring write back for users.

Detailed information about write back in views is provided in Oracle Fusion Middleware User's Guide for Oracle Business Intelligence Enterprise Edition. The following sections provide information on how you as the administrator can configure for write back:

19.8.1 Write-Back Limitations

Users can write back to any data source (except for an ADF data source) that allows the execution of SQL queries from the Oracle BI Server. As you configure for write back, keep the following limitations in mind:

  • Numeric columns must contain numbers only. They should not contain any data formatting characters such as dollar signs ($), pound signs or hash signs (#), percent signs (%), and so on.

  • Text columns should contain string data only.

  • You can use the template mechanism only with table views and only for single-value data. The template mechanism is not supported for pivot table views or any type of view or for multiple-value data.

  • All values in write-back columns are editable. When displayed in non printer friendly context, editable fields are displayed as if the user has the Write Back to Database privilege. However, when a logical column is mapped to a physical column that can change, the logical column returns values for multiple level intersections. This scenario can cause problems.

  • Any field in an analysis can be flagged as a write-back field, even if it is not derived from the write-back table that you created. However you cannot successfully execute the write-back operation if the table is not write-back enabled. The responsibility for correctly tagging fields lies with the content designer.

  • A template can contain SQL statements other than insert and update. The write-back function passes these statements to the database. However, Oracle does not support or recommend the use of any statements other than insert or update.

  • Presentation Services performs only minimal validation of data input. If the field is numeric and the user enters text data, then Presentation Services detects that and prevents the invalid data from going to the database. However, it does not detect other forms of invalid data input (values out of range, mixed text and numeric, and so on). When the user clicks the write-back button and an insert or update is executed, invalid data results in an error message from the database. The user can then correct the faulty input. Content designers can include text in the write-back analysis to aid the user, for example, "Entering mixed alphanumeric values into a numeric data field is not allowed."

  • The template mechanism is not suitable for entering arbitrary new records. In other words, do not use it as a data input tool.

  • Write-back analyses do not support drill-down. Because drilling down modifies the table structure, the write-back template does not work.

    Caution:

    The template mechanism takes user input and writes it directly to the database. The security of the physical database is your own responsibility. For optimum security, store write-back database tables in a unique database instance.

19.8.2 Configuring for Write Back

Complete the following steps to configure for users to write back values to the data source.

To configure for write back:

  1. Create a physical table in the database that has a column for each write-back field needed. In the table create statement, make the write-back fields non-null-able.

    Note:

    For optimum security, store write-back database tables in a unique database instance.
  2. Use the Oracle BI Administration Tool to configure the new table, as described in Oracle Fusion Middleware Metadata Repository Builder's Guide for Oracle Business Intelligence Enterprise Edition.

  3. Create a write-back template that specifies the SQL statements that are necessary to both insert and update values into the table that you created. For more information, see Section 19.8.3, "About the Write-Back Template."

  4. Add the LightWriteback element in the instanceconfig.xml file, as described in Section 19.8.2.1, "Setting the LightWriteback Element."

  5. In Oracle BI Presentation Services, grant the following write-back privileges to the appropriate users: Manage Write Back and Write Back to Database.

    For information, see Section C.2.3.2, "Setting Privileges in Oracle BI Presentation Services Administration."

  6. Configure a write-back analysis, as described in Oracle Fusion Middleware User's Guide for Oracle Business Intelligence Enterprise Edition.

19.8.2.1 Setting the LightWriteback Element

In order for users to write back values, you must manually add the LightWriteback element in the instanceconfig.xml file. Before you begin this procedure, ensure that you are familiar with the information in Section 3.4, "Using a Text Editor to Update Oracle Business Intelligence Configuration Settings".

To manually set the element for write back:

  1. Open the instanceconfig.xml file for editing, as described in Section 3.6, "Where are Configuration Files Located?"

  2. Locate the ServerInstance section in which you must add the LightWriteback element.

  3. Include the element and its ancestor elements as appropriate, as shown in the following example.

    <WebConfig>
        <ServerInstance>
            <LightWriteback>true</LightWriteback>
        </ServerInstance>
    <WebConfig>
    

    Note that this example does not include parameters that might exist in the file, but that are centrally managed by Fusion Middleware Control and cannot be changed manually.

  4. Save your changes and close the file.

  5. Restart Oracle Business Intelligence.

19.8.3 About the Write-Back Template

The write-back template is an XML-formatted file that contains SQL statements that are needed to insert and update records in the write-back table and columns that you have created. You can create multiple write-back templates, customizing each one for the fields that are used in each specific analysis. In the table view properties, you specify the name of the write-back template to use.

19.8.3.1 How Write Back Works

If a user has the Write Back to Database privilege, then the write-back fields in their analyses can display as editable fields if properly configured. If the user does not have this privilege, then the write-back fields display as normal fields. If the user types a value in an editable field and clicks the appropriate write-back button, then the application reads the write-back template to get the appropriate insert or update SQL command. It then issues the insert or update command. If the command succeeds, then it reads the record and updates the analysis. If there is an error in either reading the template or in executing the SQL command, then an error message is displayed.

The insert command runs when a record does not yet exist and the user enters new data into the table. In this case, a user has typed in a table record whose value was originally null.

The update command runs when a user modifies existing data. To display a record that does not yet exist in the physical table to which a user is writing back, you can create another similar table. Use this similar table to display placeholder records that a user can modify in dashboards.

19.8.3.2 Requirements for the Write-Back Template

The write-back template must meet the following requirements:

  • To meet security requirements, you must specify the connection pool along with the SQL commands to insert and update records. These SQL commands reference the values that are passed in the write-back schema to generate the SQL statements to modify the database table. Values can be referenced either by column position (such as @1, @3) or by column ID (such as @{c1234abc}, @{c687dfg}). Column positions start numbering with 1. The use of column ID is preferred. Each column ID is alphanumeric, randomly generated, and found in the XML definition of the analysis in the Advanced tab of the Analysis editor.

  • You must include both an <insert> and an <update> element in the template. If you do not want to include SQL commands within the elements, then you must insert a blank space between the opening and closing tags. For example, you must enter the element as

    <insert> </insert>
    

    rather than

    <insert></insert>
    

    If you omit the blank space, then you see a write-back error message such as "The system cannot read the Write Back Template 'my_template'".

  • If a parameter's data type is not an integer or real number, then add single quotes around it. If the database does not do Commits automatically, then add the optional postUpdate node after the insert and update nodes to force the commit. The postUpdate node typically follows this example:

    <postUpdate>COMMIT</postUpdate>
    
  • Store the write-back template files in the analyticsRes directory that the administrator has configured for static files and customer messages:

    ORACLE_INSTANCE/bifoundation/OracleBIPresentationServicesComponent/coreapplication_obipsn/analyticsRes/customMessages

    While XML message files that affect a language-specific user interface must be localized, the XML file that is used for configuring a write-back template is usually not translated, because it is language-independent.

    In the rare cases where write-back template files must be language-dependent (for example, if a user logging in using the l_es (Spanish) locale would use a different SQL command then a user logging in using l_fr (French) locale), then the write-back template messages should exist in appropriate language directories. For information, see Section 22.5, "Customizing the User Interface Using XML Message Files."

  • The write-back template files can have any name of your choosing, because the system reads all XML files in the CustomMessages folder. To ensure that write back works correctly, include in the WebMessage element of the file the name of the SQL template that you specified when you created the write-back table. You can have multiple WebMessage elements in one file, with each element specifying one SQL template.

    The following example shows the specification of the SQL template that is called "SetQuotaUseID."

    <WebMessage name="SetQuotaUseID">
    

19.8.3.3 Example: Write Back Template

A write-back template might resemble this example:

<?xml version="1.0" encoding="utf-8" ?>
<WebMessageTables xmlns:sawm="com.siebel.analytics.web/message/v1">
<WebMessageTable lang="en-us" system="WriteBack" table="Messages">
   <WebMessage name="SetQuotaUseID">
      <XML>
         <writeBack connectionPool="Supplier">
            <insert>INSERT INTO regiontypequota VALUES(@{c0},@{c1},'@{c2}','@{c3}',@{c4})</insert>
            <update>UPDATE regiontypequota SET Dollars=@{c4} WHERE YR=@{c0} AND Quarter=@{c1} AND Region='@{c2}' AND ItemType='@{c3}'</update>
         </writeBack>
      </XML>
   </WebMessage>
   <WebMessage name="SetQuota">
      <XML>
         <writeBack connectionPool="Supplier">
            <insert>INSERT INTO regiontypequota VALUES(@1,@2,'@3','@4',@5)</insert>
            <update>UPDATE regiontypequota SET Dollars=@5 WHERE YR=@1 AND Quarter=@2 AND Region='@3' AND ItemType='@4'</update>
         </writeBack>
      </XML>
   </WebMessage>
</WebMessageTable>
</WebMessageTables>