• What is dbt_artifacts?

    dbt_artifacts is a package for modeling a dbt project and its run metadata. It includes the following models to help you understand the current state of a dbt project and its performance over time. It...

  • Data migration from the Salesforce to snowflake Data warehouse by using Matillion

    Purpose of the Article: This blog explains how to load the data from Salesforce to Snowflake Intended Audience: This article will help our Organizational level kind of developers working on data migra...

  • WiMAX-A Study of Mobility

    1. Introduction The wireless market is growing rapidly; being pushed through wireless connectivity demand various wireless connectivity means are emerging (WLAN/802.11, WMAN/802.16a, WWAN/802.16d) [IE...

  • Weblogic Upgrade

    Patch Name wls1036_upgrade_generic.jar Reference https://www.youtube.com/watch?v=Be6hrYTANQE Just Click Next and Next MAKE SURE ALL OBIEE SERVICES ARE DOWN AND CLOSED IN PROCESS Open CMD prompt C:Mid...

Tags

bics installation OBIEE obiee 11g installation guide Oracle

Categories

OBIEE 11g Non Conformed

a

OBIEE 11g Non Conformed

Version 11.1.9.0

There is a great new feature introduced with Oracle BI 11.1.9 which allows report developers to overcome issues with “non-conformed” dimensions.

A non-conformed dimension is where you add an attribute to an analysis which does not logically relate to all the facts.

Take this example, here we have an analysis with 2 “facts” and 1 “conformed dimension” i.e. the “Store” dimension attribute relates to both “# POIs” and “# Orders”.

 

All is good so far!   But what happens if we introduce another dimension attribute e.g. “Year” that has no relationship with the “# POIs” fact?

You can see here that Oracle BI simply defaults the whole “# POIs” column to zero due to the fact that the fact does not relate to all the dimensions on the report:

However, with 11.1.1.9 you can overcome this by going to the “Advanced” tab within Answers and enabling the option “Show Total value for all measures on unrelated dimensions“:

 

And that’s it!   If you return to the “Results” tab you can see that the metric is now populated again – Oracle BI is calculating its values by ignoring any non-conformed dimensions:

 

Version 11.7.0.0 – 11.9.0.0

When I read the questions people ask about data modeling on OBIEE forums, one that seems to come up frequently is what to do when you have fact tables that do not join to all dimension tables.

This picture illustrates the problem. FactTable2 joins to two dimension tables, but FactTable1 only joins to only one.

Dimension Picture1

The data for this example is very simple:

Dimension Picture2

Here’s what typically happens when the naive metadata designer is finished. The first query results look good.

Dimension Picture3

But when the query contains a column from the second dimension table, suddenly the data that was there before disappears, and the first reaction is that something is wrong.

Dimension Picture4

From one perspective, these are correct result. The query asked for Fact1 aggregated by DimA and DimX. Since Fact1 does not join to Dim X, nulls are the correct answer.

Looking at the SQL generated gives you an idea of how OBIEE navigates this query. It determines that the query wants Fact1 aggregated by DimADesc and DimXDesc. The only fact table that can aggregate by those two dimensions is Fact2. Therefore, the SQL it generates uses FactTable2 in the FROM clause, not FactTable1, even though Fact1 does not map to any column in FactTable2. The BI Server is aware Fact1 does not map to FactTable2, so it returns Null (C3 in the outer query block below) as the value of Fact1.

select distinct D1.C1 as C1,
D1.C2 as C2,
cast(null as double precision) as C3
from
(select distinct T1416.DIMADESC as C1,
T1420.DIMXDESC as C2
from DIMX T1420,
DIMA T1416,
FACTTABLE2 T1429
where (T1416.DIMAKEY = T1429.DIMAFKEY
and T1420.DIMXKEY = T1429.DIMXFKEY)
) D1
order by C1, C2

However, what if Fact1 is a level-based measure, always calculated at the Grand Total level for DimX? Then the BI Server knows it does not have to aggregate by the attribute values of DimX and returns these results.

Dimension Picture5

In the SQL you can see that there is still a query block involving FactTable2. This query determines the values of  DimADesc and DimXDesc that will be in the results. The query to FactTable1 aggregates Fact1 by DimADesc. The two result sets are then fully outerjoined – even null values, if they are returned, will be joined, Null to Null.

WITH SAWITH0 AS
(SELECT DISTINCT
T1420.DIMXDESC AS C1,
T1416.DIMADESC AS C2
FROM DIMX T1420,
DIMA T1416,
FACTTABLE2 T1429
WHERE (T1416.DIMAKEY = T1429.DIMAFKEY
AND T1420.DIMXKEY = T1429.DIMXFKEY)),
SAWITH1 AS
(SELECT
sum(T1424.FACT1) AS C1,
T1416.DIMADESC AS C2
FROM
DIMA T1416,
FACTTABLE1 T1424
WHERE (T1416.DIMAKEY = T1424.DIMAFKEY)
GROUP BY T1416.DIMADESC)
SELECT DISTINCT
CASE
WHEN SAWITH1.C2 IS NOT NULL THEN SAWITH1.C2
WHEN SAWITH0.C2 IS NOT NULL THEN SAWITH0.C2
END AS C1,
SAWITH0.C1 AS C2,
SAWITH1.C1 AS C3
FROM
SAWITH0
FULL OUTER JOIN SAWITH1
ON nvl(SAWITH0.C2,’q’) = nvl(SAWITH1.C2,’q’)
AND nvl(SAWITH0.C2,’z’) = nvl(SAWITH1.C2,’z’)
ORDER BY C1, C2

As the physical query shows, results will be determined by the foreign keys of DimX in FactTable2. If the rows where DimXFKey=2 are deleted, then th
Dimension Picture6

In this Business Model, both fact table sources (for FactTable1 and FactTable2) have an aggregation content of Detail for both dimensions (Detail is the default )

Dimension Picture7dimension Picture8
Changing the aggregation content for FactTable1 does not alter the results or the SQL generated. (Note here that when one dimension has a level that is sp
Dimension Picture9

An alternate approach is to physically join DimX to FactTable1 using a complex join having the join condition 1=1. The aggregation content for both logical fact table sources can be set at Detail so that any query containing columns from DimX can use FactTable1 as a source. The measure, Fact1, no longer has to be set to Grand Total level for DimX. Since FactTable2 will not be involved in the query, the foreign key values in FactTable2 will not matter. Now the results are back to what we saw in the first query.

describe the image

However, the SQL is quite different, and you can see why all the values of DimXDesc are returned.

select T1416.DIMADESC as c1,
T1420.DIMXDESC as c2,
sum(T1659.FACT1) as c3
from 
DIMX T1420,
DIMA T1416,
FACTTABLE1 T1659 
where ( T1416.DIMAKEY = T1659.DIMAFKEY ) 
group by T1416.DIMADESC, T1420.DIMXDESC
order by c1, c2
The important points to remember are 
that a physical fact table that does not join 
to a dimension table can be made to join with
a complex join having the condition 1=1. 
The logical fact table source that contains this 
physical fact table can be set at the Detail level 
for the dimension that is joined like this. The facts 
that map to this logical table source should not 
be level-based.
Warning: Array to string conversion in /volume1/web/wordpress/wp-includes/link-template.php on line 2361 Call Stack: 0.2539 6404168 1. {main}() /volume1/web/wordpress/index.php:0 0.2540 6404480 2. require('/volume1/web/wordpress/wp-blog-header.php') /volume1/web/wordpress/index.php:17 4.1040 23112888 3. require_once('/volume1/web/wordpress/wp-includes/template-loader.php') /volume1/web/wordpress/wp-blog-header.php:19 4.1173 23123224 4. include('/volume1/web/wordpress/wp-content/themes/ayro/single.php') /volume1/web/wordpress/wp-includes/template-loader.php:106 4.7474 25211760 5. ayro_qodef_get_blog_single() /volume1/web/wordpress/wp-content/themes/ayro/single.php:9 4.7477 25212136 6. ayro_qodef_get_module_template_part($template = 'templates/single/holder', $module = 'blog', $slug = '', $params = ['sidebar' => 'default']) /volume1/web/wordpress/wp-content/themes/ayro/framework/modules/blog/blog-functions.php:459 4.7477 25212264 7. ayro_qodef_get_template_part($template = 'framework/modules/blog/templates/single/holder', $slug = '', $params = ['sidebar' => 'default']) /volume1/web/wordpress/wp-content/themes/ayro/framework/lib/qode.functions.php:907 4.7479 25213168 8. include('/volume1/web/wordpress/wp-content/themes/ayro/framework/modules/blog/templates/single/holder.php') /volume1/web/wordpress/wp-content/themes/ayro/framework/lib/qode.functions.php:888 4.7479 25213168 9. ayro_qodef_get_single_html() /volume1/web/wordpress/wp-content/themes/ayro/framework/modules/blog/templates/single/holder.php:3 4.8376 25317512 10. ayro_qodef_get_module_template_part($template = 'templates/single/parts/single-navigation', $module = 'blog', $slug = ???, $params = ???) /volume1/web/wordpress/wp-content/themes/ayro/framework/modules/blog/blog-functions.php:523 4.8376 25317656 11. ayro_qodef_get_template_part($template = 'framework/modules/blog/templates/single/parts/single-navigation', $slug = '', $params = []) /volume1/web/wordpress/wp-content/themes/ayro/framework/lib/qode.functions.php:907 4.8378 25318992 12. include('/volume1/web/wordpress/wp-content/themes/ayro/framework/modules/blog/templates/single/parts/single-navigation.php') /volume1/web/wordpress/wp-content/themes/ayro/framework/lib/qode.functions.php:888 4.8526 25369200 13. previous_post_link($format = '%link', $link = [0 => 'https://miaz-tech.com/wp-content/uploads/2016/05/shop-product-image-4.jpg', 1 => 600, 2 => 651, 3 => FALSE], $in_same_term = TRUE, $excluded_terms = '', $taxonomy = 'category') /volume1/web/wordpress/wp-content/themes/ayro/framework/modules/blog/templates/single/parts/single-navigation.php:27 4.8526 25369200 14. get_previous_post_link($format = '%link', $link = [0 => 'https://miaz-tech.com/wp-content/uploads/2016/05/shop-product-image-4.jpg', 1 => 600, 2 => 651, 3 => FALSE], $in_same_term = TRUE, $excluded_terms = '', $taxonomy = 'category') /volume1/web/wordpress/wp-includes/link-template.php:2278 4.8526 25369200 15. get_adjacent_post_link($format = '%link', $link = [0 => 'https://miaz-tech.com/wp-content/uploads/2016/05/shop-product-image-4.jpg', 1 => 600, 2 => 651, 3 => FALSE], $in_same_term = TRUE, $excluded_terms = '', $previous = TRUE, $taxonomy = 'category') /volume1/web/wordpress/wp-includes/link-template.php:2259
Warning: Array to string conversion in /volume1/web/wordpress/wp-includes/link-template.php on line 2361 Call Stack: 0.2539 6404168 1. {main}() /volume1/web/wordpress/index.php:0 0.2540 6404480 2. require('/volume1/web/wordpress/wp-blog-header.php') /volume1/web/wordpress/index.php:17 4.1040 23112888 3. require_once('/volume1/web/wordpress/wp-includes/template-loader.php') /volume1/web/wordpress/wp-blog-header.php:19 4.1173 23123224 4. include('/volume1/web/wordpress/wp-content/themes/ayro/single.php') /volume1/web/wordpress/wp-includes/template-loader.php:106 4.7474 25211760 5. ayro_qodef_get_blog_single() /volume1/web/wordpress/wp-content/themes/ayro/single.php:9 4.7477 25212136 6. ayro_qodef_get_module_template_part($template = 'templates/single/holder', $module = 'blog', $slug = '', $params = ['sidebar' => 'default']) /volume1/web/wordpress/wp-content/themes/ayro/framework/modules/blog/blog-functions.php:459 4.7477 25212264 7. ayro_qodef_get_template_part($template = 'framework/modules/blog/templates/single/holder', $slug = '', $params = ['sidebar' => 'default']) /volume1/web/wordpress/wp-content/themes/ayro/framework/lib/qode.functions.php:907 4.7479 25213168 8. include('/volume1/web/wordpress/wp-content/themes/ayro/framework/modules/blog/templates/single/holder.php') /volume1/web/wordpress/wp-content/themes/ayro/framework/lib/qode.functions.php:888 4.7479 25213168 9. ayro_qodef_get_single_html() /volume1/web/wordpress/wp-content/themes/ayro/framework/modules/blog/templates/single/holder.php:3 4.8376 25317512 10. ayro_qodef_get_module_template_part($template = 'templates/single/parts/single-navigation', $module = 'blog', $slug = ???, $params = ???) /volume1/web/wordpress/wp-content/themes/ayro/framework/modules/blog/blog-functions.php:523 4.8376 25317656 11. ayro_qodef_get_template_part($template = 'framework/modules/blog/templates/single/parts/single-navigation', $slug = '', $params = []) /volume1/web/wordpress/wp-content/themes/ayro/framework/lib/qode.functions.php:907 4.8378 25318992 12. include('/volume1/web/wordpress/wp-content/themes/ayro/framework/modules/blog/templates/single/parts/single-navigation.php') /volume1/web/wordpress/wp-content/themes/ayro/framework/lib/qode.functions.php:888 4.8597 25375216 13. next_post_link($format = '%link', $link = [0 => 'https://miaz-tech.com/wp-content/uploads/2016/05/shop-product-image-4.jpg', 1 => 600, 2 => 651, 3 => FALSE], $in_same_term = TRUE, $excluded_terms = '', $taxonomy = 'category') /volume1/web/wordpress/wp-content/themes/ayro/framework/modules/blog/templates/single/parts/single-navigation.php:82 4.8597 25375216 14. get_next_post_link($format = '%link', $link = [0 => 'https://miaz-tech.com/wp-content/uploads/2016/05/shop-product-image-4.jpg', 1 => 600, 2 => 651, 3 => FALSE], $in_same_term = TRUE, $excluded_terms = '', $taxonomy = 'category') /volume1/web/wordpress/wp-includes/link-template.php:2315 4.8597 25375216 15. get_adjacent_post_link($format = '%link', $link = [0 => 'https://miaz-tech.com/wp-content/uploads/2016/05/shop-product-image-4.jpg', 1 => 600, 2 => 651, 3 => FALSE], $in_same_term = TRUE, $excluded_terms = '', $previous = FALSE, $taxonomy = 'category') /volume1/web/wordpress/wp-includes/link-template.php:2296
No Comments
Post a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.