Oracle BI EE 11g – Parent-Child Hierarchies – Differing Aggregations

Venkatakrishnan J | Aug 24, 2010 00:10 +0000

Mark has already explained the new Parent-Child hierarchy new feature in 11g here. Parent Child hierarchies are different from normal level based hierarchies not only in the nature of their structure but also in the way aggregations are done. For example, in a level based hierarchy, the most common type of aggregation that is done involves rolling up the numbers from the lower most level. But in the case of parent-child hierarchy, an aggregation by default enforces the roll-up across all descendant members. To understand this lets try to take this through an example.

Lets consider a sales department with the employee hierarchy shown below

Its a simple parent child employee hierarchy found in the oracle HR schema. Now the requirement for us is to model the Salary attribute of an employee in 3 ways

1. As an attribute – Show the salary of each employee as an attribute in the parent child hierarchy.
2. As a measure (All intermediary Roll-ups) – Roll-up the salary figures of all the employees who roll into the employee. For example, Scott King will have a Salary equal to sum of salaries of all the employees who report to him, including the ones who are his direct & in-direct reporting employees.
3. As a measure (Level-0 Roll-up) – Roll-up the salary figures from the lower most level till the top node For example, in the above figure, Scott King will have a Salary Roll-up figure of all the employees who are the lowermost level (not including the intermediary nodes – very similar to normal level based hierarchy roll-ups)

The above requirement is quite straightforward, but to achieve similar such aggregations in a normal level-based hierarchy, we will have introduce fragmentation & other techniques. But with parent-child hierarchy modeling now available in BI EE, all the above 3 requirements can quite easily be achieved.

Following is the employees parent child table that stores all the attributes of an employee

We start off with modeling this as a normal dimension table. As shown in Mark’s blog entry, we then create the Parent-Child table that stores all the relationships within the employee hierarchy (if you look at the script used in creating this, it will be containing a Connect By statement that will connect a root hierarchical node to every member that is part of its hierarchy).

Once this is created, we start with including the Salary as an attribute within the Employee dimension itself

This will serve our first requirement i.e show salary as an attribute of every employee. Now, to model the 2nd requirement i.e. to model salary as a measure and then make it to rollup from all the intermediary hierarchical members, we start with defining an alias on the main Employee table. Then join this table to the custom parent child employee table. The join structure of all the 3 tables is given below

We would then be using the salary column from the new employee alias table in our logical fact table as shown below

Lets now look at the report now and see what BI EE generates.

As you see, BI EE has generated the correct results with the roll-up of intermediary members as well. This is something that is quite difficult to model in BI EE 10g. If we look at the query generated (just the key one that generates the measure as BI EE now generates lots of intermediary sub-queries to support contextual drilling) you would notice that the default Parent-Child behavior is to achieve a roll-up across a hierarchy

To achieve the 3rd requirement i.e. to model a level based hierarchy kind of rollups from level-0, we create another alias in the physical layer and then model it the same way as the 2nd requirement. In the fact logical table, we then create a new measure that will map to the new physical alias as shown below

To ensure that we roll-up only from level-0 members, we then apply a filter in the fact logical table source as shown below

Lets now take a look at what BI EE generates

As you see, BI EE now generates the roll-ups only from level-0 members as against every descendant. We can have even more granular roll-ups based on custom defined attributes.


New Masterclass Dates, Including Australia and Singapore

Mark Rittman | Aug 23, 2010 05:00 +0000

As well as the three Rittman Mead OBIEE 11g Training Days events we’re running in London, Atlanta and Bangalore later this year, I’ve also agreed to do a number of Enterprise Business Intelligence Masterclasses for Oracle University, including a visit down to Australia and Singapore. These events are seminar-style, cover OBIEE 11g as well as OWB11gR2/ODI 11gR1 and a bit of Essbase 11.1.2, and are an ideal high-level introduction to the technology behind the Oracle 11g BI&DW technology stack.

mr_ou_bi

More dates will be announced over the next few months, but for now, here’s the current set of confirmed dates and venue:

I’ll post details of any future events on our Events website page.

Oracle MOS HTML Update 22082010

Daan Bakboord | Aug 23, 2010 04:52 +0000
 Document ID   Title   Doc Type   Modified Date  1179676.1 Do We Need A Separate Mds, Biplatform Schemas Per Obiee Instance? HOWTO 18-AUG-10 1179563.1 Installing Oracle Bi Administration Tool On A Windows7 Client HOWTO 18-AUG-10 1180363.1 Documentation For Oracle Business Intelligence 11g and 10.1.3.4.1 Upgrade HOWTO 18-AUG-10 1178017.1 What OBIEE Repository setting need to be changed when [...]

OBIBB – Interviews (Kurt Wolff)

Daan Bakboord | Aug 23, 2010 02:36 +0000
It has been quite some time since the last interview in the series on this blog, but I think it has been worth the wait.  I have been able to ask Kurt Wolff some questions. He has taken his time to give some very interesting answers. 1. You are a well respected member of the Oracle [...]

Installing OBIEE 11g

Abhinav Agarwal | Aug 23, 2010 01:11 +0000
To install Oracle BI EE 11g, after you have downloaded the install files, and unzipped them, you need to go to "Disk 1", and run the "setup.exe" file (on Windows; on Linux it would be the "runInstaller" file)


This launches the Oracle Universal Installer (OUI for short). Don't get confused by the "Oracle Fusion Middleware 11g" logo at the top, since Oracle BI EE is part of the Fusion Middleware

Oracle BI EE 11g – Upgrading from BI EE 10g – Repository & Web Catalog

Venkatakrishnan J | Aug 22, 2010 21:49 +0000

BI EE 11g is a significant feature filled release when compared with the previous 10g release. Most customers who are planning to upgrade to 11g have an automated way of upgrading their 10g Web Catalogs and repositories to the 11g version. When moving from 10g to 11g, we will have to go through the upgrade utility as there are significant changes to the repository structure and the web catalog structures. A direct copy & paste into the 11g version will not work.

The upgrade process involves the following steps

1. Install the new 11g version in either the same machine or a different machine.
2. Run the upgrade assistant utility to upgrade the repository & Web Catalogs.
3. Migrate other 10g specific customizations manually to the 11g instance. The different customizations are

a. Any Static files added to the 10g app server
b. Custom XML messages
c. Styles & Skins (The upgrades for this will have to be done carefully as some CSS & files have changed in this release)

4. Upgrade the Scheduler schema (Both BI Delivers & BI Publisher) through the upgrade utility
5. Upgrade BI Publisher

In this blog entry we shall see how to go about upgrading the RPD and Web Catalogs from the 10g to the 11g version. After installing 11g, start up the upgrade assistant utility from {ORACLE_HOME}/bin/ua (or ua.bat if you are on windows)

The upgrade assistant can be used to upgrade the scheduler schema, BI Publisher as well as the RPD & Web Catalogs. Lets start with the first option, i.e. upgrading RPD and Web Catalogs

In the upgrade screen, choose the 10g RPD along with the Web Catalog Path. In the Deliveries folder, choose the 10g deliveries path ({OracleBIData}/web/catalog/deliveries

In the next screen, provide the details of the weblogic server on which we will be deploying the Repository and Web Catalog to.

The upgrade utility does not seem to support remote deployments of the RPD and Web Catalog i.e. Upgrade Utility will only deploy the repository and web catalog on the machine containing the weblogic admin server.

The upgrade process will stop all the components first and then will do the individual RPD and Web Catalog Upgrade.

This is just a utility. We cannot expect all the reports to start working out of the box immediately after an upgrade. Good amount of testing is required to make sure all the older queries of the most commonly used reports are working without any major issues. Also, not all the reports would get migrated seamlessly due to the significant changes across the versions which the utility cannot recognize. Care has to be taken to make sure that all the warnings logged as part of the upgrade process are properly analyzed and corrected manually. A sample upgrade log is shown below (containing 4 warnings)


OBIEE11g Download – Yes, It’s Finally Here!

Christian Screen | Aug 20, 2010 11:23 +0000
So, to much excitement, the first GA release of OBIEE 11g is finally available for the public to download.  You can download it as Friday August13, 2010 from the OTN OBIEE Page.  There is a lot to say for this release and our good friends at BI Consulting Group and Rittman-Mead have already begun blogging [...]

Oracle BI 11g Documentation

Daan Bakboord | Aug 20, 2010 04:57 +0000
All the credits should go to Christian Turri (aka Turribeach) for his investigations and willingness to share. The Oracle Business Intelligence Documentation could be found in the Oracle BI Documentation Library The Certification Matrix (Thanks to Joe Bertram als) could be found here. Last but not least. Follow this link for the Oracle BI 11g [...]

Listing DBMS_Scheduler Named-Calendar Dates with SQL

David Aldridge | Aug 20, 2010 03:26 +0000
Just a quick follow up to my post from the other day about using DBMS_Scheduler to generate lists of dates in SQL. I mentioned that you can use named schedules in this method, and that’s actually a handy way of testing your schedule definition. The syntax is along the lines of: begin dbms_scheduler.create_schedule( schedule_name => [...]

Oracle BI EE 11g – Reporting on CLOBs – Lookups

Venkatakrishnan J | Aug 20, 2010 03:00 +0000

One important new feature of BI EE 11g is the ability to report on CLOBs and other large objects. The main difference between normal Varchar/Numeric columns and LOB datatype columns is, LOB columns do not support GROUP BY, DISTINCT & ORDER BY operations on them (from a reporting perspective). Any query that BI EE generates will always have a GROUP BY or a DISTINCT in it. So, in 10g reporting on LOB columns have always been an issue(will result in Ora-XXXX errors). One had to resort to different types of workarounds for reporting on LOB columns.

In BI EE 11g, its possible to isolate different columns from the GROUP BY/DISTINCT operations by using the SPARSE/DENSE lookup operators. I have already blogged about how Sparse & Dense lookups work in general here. Lets see how the same can be used for CLOB reporting. To demonstrate this i shall be using the v$sql view. This view basically contains a CLOB called SQL_FULLTEXT. This column contains the SQL queries stored in the form of CLOB, that are fired to the Oracle database by multiple users. Our aim is to report on this view and display the SQL Queries from the CLOB column.

We start with granting select on the v_$sql view to SH schema and then importing it in BI EE.

Then edit the column properties of the SQL_FULLTEXT column and increase the size to 100000 (or higher) so that BI EE can display the values from CLOB.

Start with modeling a dimension and a fact in the BMM layer as shown below

Then create another logical table (same as the dimension) containing SQL_ID as the primary key. The idea is to use this primary key and show the SQL_FULLTEXT using a DENSE lookup. Mark the new logical table as a lookup table.

In the dimension logical table create a new column and use the following formula to derive the SQL_FULLTEXT as a lookup column. This will always push a separate SQL without DISTINCT/GROUP BYs on the SQL_FULLTEXT column.

Lookup
(DENSE
"LOB Reporting"."Lookup - CLOB"."SQL Full Text" ,
"LOB Reporting"."Lookup - CLOB"."SQL ID" )

Lets now include this new column in the presentation layer and use it for reporting.

As you see, we should now be able to see the CLOB data without any restrictions. If we look at the query generated, you can basically see 2 separate SQL queries, one with the group-by and the other with just the lookup.

select sum(T43900.ROWS_PROCESSED) as c1,
     T43900.SQL_ID as c2
from
     SYS.V_$SQL T43900
group by T43900.SQL_ID
select T43900.SQL_FULLTEXT as c1,
     T43900.SQL_ID as c2
from
     SYS.V_$SQL T43900

In BI EE 11g, usage tracking can now log logical sql’s greater than 4000 characters into a separate CLOB column.