0% found this document useful (0 votes)
408 views152 pages

Business Objects Developer Training (Bo - Developer - L1) Day 1

This document provides an agenda and overview for a one-day Business Objects Developer training module on designing universes. The module covers topics such as creating universes, connecting to databases, selecting tables and columns, building classes and objects, defining joins, and restricting data. Key aspects of universe design like what a universe is, the typical layout with objects and classes, and the different types of objects and classes are explained. The document outlines the five-stage universe development process and provides steps for tasks like creating a new universe, setting universe parameters, inserting tables, defining classes and objects, and creating and deleting joins.

Uploaded by

krishna213666
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
408 views152 pages

Business Objects Developer Training (Bo - Developer - L1) Day 1

This document provides an agenda and overview for a one-day Business Objects Developer training module on designing universes. The module covers topics such as creating universes, connecting to databases, selecting tables and columns, building classes and objects, defining joins, and restricting data. Key aspects of universe design like what a universe is, the typical layout with objects and classes, and the different types of objects and classes are explained. The document outlines the five-stage universe development process and provides steps for tasks like creating a new universe, setting universe parameters, inserting tables, defining classes and objects, and creating and deleting joins.

Uploaded by

krishna213666
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 152

Business Objects Developer Training

(BO_DEVELOPER_L1)
Day 1

1
DESIGNER MODULE
Agenda

•Creation of Universe

•Connecting to Databases

•Selecting Tables and columns

•Creation of classes

•Creation of objects

•Joins

•Data Restriction
What is a Universe

 A universe is a semantic layer that maps the data


structure found in databases (tables, columns, etc)
in business terms.
 A universe can represent any specific business
area, process, or department. For example, a
universe can relate to a department in a company
such as marketing or accounting.
Business Objects Designer
A typical universe layout...

Objects

Classes

Universe Pane Structure Pane


Class

• A class is a logical grouping of objects within a


universe. In general, the name of a class reflects a
business concept that conveys the category or type
of objects.
• A class can be further divided into subclasses.
• As a designer, you are free to define hierarchies of
classes and subclasses into a model that best
reflects the business concepts of your company.
Objects
 An object is the most refined component in a
universe. It maps to data or a derivation of data
in the database.
 Types of objects -
 Dimension Objects -
 Focus of analysis in a query.
 Maps to one or more columns in a database that are key to a query.
 Measure Objects -
 Aggregate functions that map to statistics in a database.
 Map to “fact attributes” of a star schema.
 Detail Objects
 Descriptive data about the dimensions.
 Always attached to a dimension.
Five stages in universe development process

• User Requirements
– Detailed analysis of the information needs of the users.

• Data Analysis
– Detailed data analysis of the database breaking it down
into functional areas that users can relate to.

• Design
– Information from first 2 phases must be amalgamated to
create the conceptual design of the Universe, its objects
and other components.
• Development and distribution
– Create using the Designer module.
– Test using the User module.
– Distribute to the users via the repository.

• Maintenance
– Designer is responsible for updating and maintaining
Universe and keeping it up to date with any changes in the
User Requirements.
Creation of the Universe

Define the Parameters


Resolve the Loops

Insert Tables

Create Classes and Objects

Make the Joins

Set up Hierarchies
Creating a Universe

• To begin creating a new universe:


Select File, New

• To access the Universe Parameters dialog box


for an existing universe:
Select File, Parameters
or
Click on
Setting up Parameters : Definition Tab

• A universe is identified with a user name and a


connection to the database
• A detailed description can also be added
What Is a Connection?

• Definition:
– A connection is a link from the universe to
the Target database.
– The link is achieved using middleware (for
example ODBC).
– An existing connection may be used or a
new connection created for a universe.
– There are three different types of
connections.
Different Types of Connection

Personal
Can only be used on the client

Shared
Can be used by more than one user to send queries to the
target database from a shared server

Secured
This connection is used when you wish to distribute the
completed universe to the user population via the repository
Creating a New Connection
1. Click on New.

2. Choose the middleware

3. Identify the driver to be used


to access the target database
Setting up Universe Parameters
• Definition Tab: name, description and
connection to the database
• Summary Tab: author and statistics
about the universe
• Strategies Tab: internal or personal
wizards to make creating a universe
easier
• Controls Tab: manages access and
control of resources
• SQL Tab: queries and SQL
parameters
• Links Tab: enables dynamic links with
other universes
Setting up Parameters : Summary Tab
• The Summary tab displays general information about the universe
Setting up Parameters : Strategies Tab

Provides automated
strategies for:
• Creating objects
• Setting joins
• The Table browser
listing
Universe Strategies

A strategy is a script that reads structural


information from a database or a flat file.

DESIGNER uses strategies as an aid for creating


the components of the universe - objects, tables
and joins.

In DESIGNER, strategies are of 2 types -


– Built-in Strategies
– External Strategies
Built-in Strategies

Built-in strategies are pre-decided strategies that


are available with any installation of Business
Objects.

DESIGNER uses the following built-in strategies


for creating the components of universes:
– the Objects Creation strategy, which tells DESIGNER how to
define classes and objects automatically from the database’s tables
and columns
– the Joins Creation strategy, which tells DESIGNER how to define
joins automatically from the database’s tables and columns
– the Table Browser strategy, which tells DESIGNER how to read
the table and column structures from the database’s data dictionary
Built-in Strategies
To enable automatic creation, the following must be
checked….
Setting up Parameters : Controls Tab

• These allow you to limit


the size of results and
restrict the time allowed
for executing queries

• The Supervisor can


change these
parameters for specific
groups or users
Setting up Parameters : SQL Tab

• SQL parameters are


used to define the
limits of the SQL that
may be generated by
the universe
• The Supervisor can
change these
parameters for
specific groups and
users
Setting up Parameters : Links Tab

• Enables
dynamic links
with other
universes
Saving a Universe

• Save the universe using a maximum of eight characters with


up to three characters as an extension

• This makes it possible to distribute the universe across


different kinds of computers

• Choose File, Save or click


• By default the universe is saved in the folder:
c:\Program Files\Business Objects\BusinessObjects
5.0\universe
Adding Tables

• Use the Table browser:


– Double-click on the background of the Structure

– Click on

– Choose Insert, Tables from the menu

• The Table browser displays all the tables and


views of the database

• You can select multiple tables using the Shift


key or Ctrl key

27
Customizing Table Insertion

• Select Tools, Options then click on the Database tab

• From here you can select and


deselect options related to
table insertion
• You can set internal
strategies
to:
– automatically extract
joins
– detect cardinalities
– create objects when
inserting tables
Creating classes

Manual Creation
– Use “Insert > class” from the menu. An ‘Edit
Properties’ box appears. Enter class description.

OR

– Use to create a
class
Automatic creation
– Select a table in the structure pane.
– Drag it to the universe pane.
– A class is created in the universe pane with the same name as the
table name.
– Objects are also created automatically in the class corresponding
to the fields in the table.
Creating objects

Manual Creation
– Select the class where object is to be created.
– Use “Insert”--> “Object” from the menu. An ‘Edit
Properties’ box appears. Enter object details.

Automatic creation
– Select a column from a table in the structure pane.
– Drag it to the universe pane.
– An object is created under the nearest class to the point
where you drop the column.
– Default object name is column name with underscores
replaced with spaces.
Object Properties
Three property pages
– Definition
• Name
• Data type
• Description
• SELECT statement
• WHERE clause
• Properties
– Qualification
– Associated
List of
Values
Aggregate
projection
– Applicable
only to
measures.
– Defines how
the measure
will be
aggregated
when
projected from
a micro-cube.
• Advanced
– Security
– User rights on
Objects
– Date Formats
Joins
Joins

WHAT THEY ARE - Relationship between 2 or


more tables that help restrict the result set of a
query run against those tables.

WHY USE - they limit the occurrence of a


Cartesian product, a situation in which all
possible combinations between each row of each
table are retrieved.
Types of Joins

• Equi-Join
– Table 1.Column A = Table 2.Column B
– Resulting data set limited to values common in Column A & B.
• Outer-Join
– Table 1 OUTER JOIN Table 2 on Column A = Column B
– Resulting data set limited to ALL the values in Table 1 and ONLY
matching values in Table 2 based on Column A and Column B.
• Theta-Join
– Table 1.Column A BETWEEN ….. AND ……
– Links tables based on a relationship other than equality between 2
columns.
Creating and Deleting Joins

• A join can be entered manually using two methods:


– Graphically

– With the menu option Insert,


Joins and the Edit Join box

– To delete a join, click on the join line and press


Delete
39
HANDS ON WORKSHOP
Exercise 1
•Create a universe called “ VACATION ”
•Create a new connection
•Use ODBC Driver.
•Connection Name “ Vacation-Connection ”
•Use “ CLUB ” datasource
•Connection type should be “ Personal ”
•Remove the limits of 5000 rows and 10 minutes for
query time execution.
Identify the windows in the interface...

• Class and the Object or


Universe Window
• Structure Window
• Table Window
Exercise 2
• The universe Vacation should have two Classes
Customer & Sales Details.
• Customer must have 2 objects Customer-Id &
Customer-Name (Full Name)
• Sales Details must have two objects Invoice Date &
Invoice-Id.
• Customer (class) must have 2 detailed objects namely
Phone number & Address giving additional info. about
Customer Name.
• Create an appropriate join between Customer and Sales
tables.
• Save your work in the default location.
Observe the Properties for an Object

For the object Customer Name -

• Definition Tab

• Properties Tab

• Advanced Tab
Exercise 2A

• Query 1 -
– Create a query which gives details about Customer
Names and their Invoice ID
– Run the query

• Query 2
– Find Out the number of customers for which the
invoices have not been created from Vacation
Universe.
Exercise 2B

• Customer class has 2 detail objects namely Phone


number & Address giving additional info. about
Customer Name.
• Add another detail object called Age Range which
specifies age range for the customer.

Hint :- Use Age Range table ;Use Theta join between age ;
max ; min
Exercise 2C
• In the Vacation Universe create third class called
“Sales Measures”.
• In this class create a measure object called
revenue.
• Save the universe and test in user module.
• Notice the variation in “Group By” clause.

• Hint :- Revenue = (days) x (nb of guest) x (price)


Use Service & Invoice line table
Exercise 2D
• Create dimension objects City , Region & Country
in Class Customer
• In the user module create a data provider using
Customer Name, Country & Sales Revenue.
• Using Slice and Dice Panel remove Customer name
from the query.
• See the changes in Sales Revenue.
• In Designer Module set Function = None
• Repeat all the above steps
Restricting Data
Types of Restrictions

• Hard Coded / Direct Restrictions

• Indirect Restrictions

• Flexible Conditioning of the Data

• Multiple Prompt
Hard-coded Restriction
• Adding a WHERE condition to an object allows you to give a
more precise definition:
How Data is Restricted

• The Where clause in an SQL statement restricts the


number of rows returned in the result set:
WHERE WHERE
... join definitions ... ... join definitions ...
AND Country=‘United Kingdom’
Indirect Restriction

• Achieved using conditional objects


• In the User Module , user has the option to
apply the restriction.
• Obviously , more flexible than previous
type of restriction.
• Once a conditional objects are included,
restriction becomes hard-coded for the
query.
Condition Objects

• Select Condition Object View


• Insert a Condition Object

• Condition object name


• Description

• Where clause
Flexible / @Prompt type Restriction

• Offers maximum flexibility

• Limitation of Indirect type of restriction is


overcome by having flexibility in selecting
the where clause.

• Achieved using @Prompt Command.


@Prompt Command Syntax

• Message in the Prompt ‘Any Message’


• Data Type ‘A’ or ‘N’ or ‘D’
• List Of Values
– Hard Coded List of Values {‘Japan’, ‘USA’,’France’}
– Values of existing Objects
• Number of Choices Mono ; Multi
• Type of Choice Free ; Constrained
Multiple Prompt Conditioning

• Extension of @Prompt Conditioning


• More than one where clause can be prompted.
• If the same ‘Message text’ is used in the next
prompt, the user is prompted only once and the
same value is substituted for the next prompt too.
For instance, consider the following where clause -
WHERE column A = @prompt(‘Enter value’,…...)
AND column B = @prompt(‘Enter value’,…..)
This will result in the user being prompted only once and the
same value will be substituted for column B as well.
HANDS ON WORKSHOP
Exercise 3

• Add a dimension object called “ Customer


Name(French)” to class Customer. The
new object should show only French
Customers.
• Save the Universe.
• Test in User Module.
Exercise 4

• Add a condition object called “ French


Only” to class Customer.
• Set the conditions for the new object.
• Save the Universe.
• Check things in User Module.
Exercise 5

• Add another condition Object “City-user-


prompt” to class Customer.
• Set the conditions for the new object using
@Prompt Command
• Save the Universe
• Check things in User Module
Business Objects Developer Training
(BO_DEVLOPER_L1)
Day 2

6
Agenda

•List of Values

•Hierarchies

•Resolving Loops

•Maintenance of Universe
List of Values
What is a List of Values?

• A list of the distinct values from the column or


columns to which the object refers
• A LvoV is used on the operand side of a condition in
the query panel of the User module

• This is only available if set by the designer


Creating a List of Values

• A LOV is created within the Properties tab of an object

• By default,
Associate a List and
Allow Users to edit
are checked:
• It is important to un
check this box for
objects that do not
need a list
Controlling How Lists are Refreshed

• Normally, the first time a LOV is used in a User login


session, the system files a query at the target
database.
• The results of this query are used to populate the list, and are stored in the .lov file.

• There after, the .lov file from this query is used


each time the List is required.
Controlling How Lists are Refreshed

• Not normally used -


uncheck this box

• Check this box for frequently


changing lists

• Check this box for lists that


never change
Modifying the Content of a List of Values

• You can limit the values returned by applying a


condition to the LOV

• You can simplify the process of choosing a value for


Users by creating a hierarchy for the LOV

• You can supply a personal data file containing


the values for the list, instead of using the
results of the query
Applying a Condition to a List of Values

• Click Edit in the Properties box:

• Apply the condition in the Query


Panel:
Creating a Hierarchy for a List of Values

• Click Edit in the Properties box:

• Place the hierarchy objects (which


must be sorted) to the right of the
LOV object in the Query Panel:
Creating a Hierarchy for a List of Values
• The resulting Hierarchical View of the LOV makes it
easier to select the required value:

• Country:
• Town:
• Showroom:
Basing a LOV on a Personal File

• Select Tools, Lists of Values from the Menu bar:

• Select the object:

• Select Personal Data:


Basing a LOV on a Personal File
• Click OK to acknowledge the message:

• Specify the file that contains the values for the list and click OK
HANDS ON WORKSHOP
Exercise 1

• Edit the LOV for object City. The list should


display only cities for the US as the country of
origin.
• Edit the LOV for object City and create a
hierarchical LOV consisting of Country, Region
and City.
• Edit the LOV for City and base it upon a personal
file …\Universe\City_LOV.txt
Hierarchies
Hierarchies
• An ordered set of related dimensions.
• For example, A hierarchy called Geography may consist of
Country, Region and City.
• Necessary to ‘drill up / down’ to see less or more
details.
• Designer uses the class structure as the default
hierarchy.
• Custom Hierarchies can be built using Tools >
Hierarchies. A Hierarchy editor pops up. Use this to
create new hierarchies.
•Some classic examples for hierarchies -
• Products - Category > Brand > Product
• Time - Year > Quarter > Month > Week > Day
What is a Hierarchy?
• An ordered set of related dimensions.
For example, A hierarchy called Geography may consist of Country,
Region and City.
Level in Hierarchy Data Returned

U.K.

North South

Liverpool Manchester Newcastle London Southampton Bristol


What is a Default Hierarchy?
• A Default Hierarchy is the hierarchy based on the order of the
Objects within the Class

Default Hierarchies are


represented in the User
module by the order in which
Dimension Objects are
organized in the Classes and
Objects box of the Query
Panel
The key to creating Default Hierarchies

• The designer must ensure, wherever possible, that


Dimension Objects are organized from the most general to
the most specific within the Class
What is a Custom Hierarchy?
• A Custom Hierarchy combines Objects from Default
Hierarchies to build a Custom Analysis Path

Custom Hierarchy

Default Hierarchies
Creating Custom Hierarchies

(or Tools,
Hierarchies)

• Add Objects from Default Hierarchies to build a new


Custom Hierarchy
Automatic Time Hierarchy

• A time
hierarchy
can be built
automaticall
y for date
objects.
HANDS ON WORKSHOP
Exercise 2

• Make a copy of the Island resorts marketing


universe (Beach.unv) called TEST.unv
• Create a custom hierarchy in this universe that
consists of Customer, Service Line, Service.
• Test this out in the User Module.

• For the VACATION universe, create a Automatic


Time Hierarchy on the object called Invoice Date
in the class Sales Details.
• Save the Universe and test this out in the User
Module.
Loops
What is a loop?
• What is a Loop
Multiple paths between the tables selected in queries.
Detecting Loops
Detecting Loops
Loops can be resolved by..
ALIASES
• Alias - Same as the namesake in SQL.
• Exact duplicate of the original table.
• A different name “tricks” the SQL query to
accept that you are using 2 different tables.
CONTEXTS
• Rule which helps BO decide which of the 2
paths to choose in a loop.
• BO prompts the user to indicate the correct
perspective (relevant path) for the query.
When to Alias

• A loop with a single N N


lookup table should be
resolved by an alias
1

N 1
• A lookup table can 1
be identified by its N

N
cardinality 1 1

• A lookup table only


has the ‘one’ end of Alias needed here
joins attached to it
How to Alias

• Designer routines
detect loops and
candidates for
aliases
• Break the loop by
creating an alias of
the lookup table for
each side of the loop

Do not remove the


original table
Resolving Loops using Contexts

Sales Sal
Lines

Customers

Loans
There are two possible routesLoans
to
link Clients with Models: Lines

• Working with rentals


• Working with sales
Detecting and Creating Contexts

• Loop Detection routine: suggests


candidates for both aliases and
contexts
• “Detect Contexts” detects and
proposes a list of contexts to create

• “Insert Contexts” inserts a context


manually
HANDS ON WORKSHOP
Exercise 3

• Add following table to the Vacation


Universe
– Service_line
– Resort
• Use Alias to Solve the loop
• Complete the universe Designing
• Save the universe as Vct-Als
• Test the new universe in the User Module
Exercise 4
• Add following table to the Vacation
Universe
– Service_line
– Reservation
– Reservation_Lines
– Resort
• Solve the loop
• Complete the universe Designing
• Save the universe as Vct-Con
• Test the new universe in the User Module
Universe Maintenance
Reasons for Universe Maintenance

• New tables added to database


• Tables deleted, changed or renamed in database
• Users request new classes or objects

Note: Your primary concern when you introduce a new


version of a universe should be what effect it will
have on existing end user reports
Changes to the Target Database

• The implications of modifying the underlying


database for Business Objects universes
varies in severity:
 No Impact:  Severe Impact:

 Adding new  Renaming/moving database


columns  Changing existing column
 Adding new and table names
tables  Deleting tables and columns
Detecting Changes to the Universe
• Choose View, Refresh
Structure
• Changed tables are
highlighted in the
Structure
• A message on the screen
indicates that tables have
been deleted
The Effect of Changing Objects

• Changes to existing Objects in a Universe can


have an impact on existing Documents created
from the Universe:

 No Impact:  Impact:

• Redefining Object SQL • Deleting an existing


• Renaming an Object Object
• Copying to different Class • Deleting and then
• Moving in same Class or to recreating an object with
a different Class exactly the same
• Adding new Objects definition
Business Objects Developer Training
(BO_DEV_L2)
Day 1

INF Technical Training


Agenda

•@ functions

•Fan trap and Chasm trap in Designer

•Linking of Universe.
•Migration of Universes
@ Functions
Topics @Functions

–Types of @functions

–Syntax & Usage


Types of @functions
The types of @functions are:

– @prompt()
– @select()
– @variable()
– @where()
– @script()
– @aggregate_aware()

•These functions are applied in the Select and Where clauses of an


object
@Prompt Syntax
Syntax -
@prompt(‘message’,[‘type’],[lov],[MONO|MULTI],[FREE|CONSTRAIN])

•message is the text of a message within single quotes.


Examples of messages are: ‘My Variable’, ‘Choose a Region’, ‘Pick a time
period’.
• type is one of the following: ‘A’ for alphanumeric, ‘N’ for number, or ‘D’ for
date.
• lov can be either a list of values enclosed in brackets; each value must be within
single quotes and separated by commas:
{‘myval1’,‘myval2’,‘myval3’...}
or
the name of a class and object separated by a backslash and within single quotes:
‘myclass1\myobject1’

• MONO means that the prompt accepts only one value. MULTI means that the
prompt can accept several values.

• FREE refers to free input as opposed to CONSTRAIN, which means that the end
user must choose a value suggested by the prompt.
@Prompt

Country.Country_name = @prompt(Prompt
message-‘Select the country’,Data Type (‘A’, ‘N’,
‘D’)-‘A’,LOV name - ‘Country\Country’,Or
hard coded list - {‘India’;’US’},LOV selection-
MONO,To value in LOV- FREE )
@Prompt

@Prompt snapshot
Multiple @Prompt
Extension of @Prompt Conditioning
More than one Where clause can be prompted.

If the same ‘Message text’ is used in the next prompt, the user
is prompted only once and the same value is substituted for the
next prompt too.

For instance, consider the following where clause -


WHERE column A = @prompt(‘Enter value’,…...)
AND column B = @prompt(‘Enter value’,…..)

This will result in the user being prompted only once and the
same value will be substituted for column B as well.
Cascading @Prompts
• Are prompts that get popped up in hierarchical manner.
• Each prompt will only contain the values associated with the previous
prompt.

Two things are required for a nested LOV to work at Designer,


• LOV’s set up properly in the Universe.
• Very important…You must use the LOV objects when building the
report as part of the query condition. You must also select the “Associate
list of values” option.

For example, to create a Prompt that prompts based on


geographical hierarchy
-State
-City
-Store name
If you select California, your next prompt will have San Francisco
and Los Angeles. Select Los Angeles and you will be able to only
select a store from the Los Angeles area -- eFashion Los Angeles
will show up.
Cascading @Prompt
Steps to use this function, (using eFashion Universe)
1) Select the lowest level in the hierarchy. In this example, I selected “Store
Name”.
2) Double-click and select the “Properties” tab. Select only the “Automatic
Refresh before each use”. Click the “Edit” button.
3) Ensure the item selected from #1 (in this case “Store Name”) shows up in the
“Result Objects” panel.
4) Select the next level up in the hierarchy. The next level up in this example is
“City”.
5) Drag and drop this next level into the “Conditions” panel. In the Operators
section on the left, select any related operator. From the Operands section on
the left, select “Type a New Prompt”.
6) Type in the name of this prompt. Typically it is the same name as
the object dropped into the “Conditions” panel as shown below. Click on
the “OK” button. DO NOT click the “RUN” button.
7) Repeat the above steps for all remaining levels of the hierarchy.
Note that the highest level will not have a condition.
8) Open Business Objects, Select Store Name and any measure, but
the Store Name should also have a prompt for itself
@Select
• Allows to use the Select statement of another object, creates a dynamic link
between two objects. Any change in the parent will affect the child
• @Select function acts as a pointer to the Select box of another object: @Select
(Class_Name\Object_Name)
@Where
•The @Where function acts as an indicator to the Where box of another
object
•Creates a dynamic link between objects
@Where (Class_Name\Object_name)
@Variable
Used to reference the value assigned to a variable or name
Syntax - @Variable(‘myname’)

”Myname” - Can be text of an interactive object (i.e the first argument


in an @Prompt function)
OR
- System variable names BOUSER or BOPASS
@Script

•Function recovers the results of Visual Basic for


Applications macro (VBA macro).
•The syntax @Script (‘var_name’, ‘vartype’, ‘script_name’)
where

var_name – variable name declared in the script (VBA)


var_type – variable type declared ‘A’ for alphanumeric, ‘D’
for date, ‘N’ for numeric
script_name – script file name to be executed
@Aggregate_Aware

• Feature available in Designer that makes use of Summary


tables in the Database

• A universe that is “aggregate_aware” has one or more


aggregate objects that correspond to levels of aggregation
Example – Revenue object can be aggregated by month,
quarterly and Yearly.

• Aggregate awareness is more important in Data warehouse


@Aggregate_Aware Function

–Definition of @aggregate_aware

–Syntax

–Procedure to create @aggregate_aware


Definition of @Aggregate_Aware

• Aggregate Awareness is the BusinessObjects process by


which higher level aggregates are incorporated into a
Universe

• Feature available in Designer that makes use of Summary


tables in the Database

• A universe that is “aggregate_aware” has one or more


aggregate objects that correspond to levels of aggregation
Example – Revenue object can be aggregated by month,
quarterly and Yearly.

• Aggregate awareness is more important in Datawarehouse

• Queries built from such a universe return information


aggregated to the appropriate level
@Aggregate_Aware Syntax
Syntax -
@Aggregate_Aware(sum(agg_table_1), ., ., ., sum(agg_table_n))

• where ‘agg_table_1’ is the table with the highest level of aggregation


• ‘agg_table_n’ is the table with the lowest level of aggregation

An example of Data warehouse, organized in three dimensions: time,


geography and product
@Aggregate_Aware
• Day is the lowest level of aggregation in Time dimension
and the highest level of aggregation is Year
• City is the lowest level of aggregation in the Geography
dimension and the highest level of aggregation is Country

• Data warehouse (DW) store daily information at its lowest


level about customer and products.
DW contains one row for each customer’s daily product
purchases; which mathematically can be represented as
365 days * 100 cities * 10 products = 365, 000
rows!
To seek information of yearly sales database engine has to
add up this many number of rows.

• A summary table based on the level of aggregation solves


this problem
Procedure to create @Aggregate_Aware
It’s a four part process:
Step 1: Build the objects
• Identify all the possible definitions (table/column
combinations) of the objects
• Arrange the objects by level of aggregation
• Build the objects using the @Aggregate_Awareness function

Step 2: Specify the incompatible objects


• Build an object/aggregate tables matrix
• For the first aggregate table, decide whether each object is
either
– at the same level of aggregation or higher (compatible)
– at a lower level of aggregation (incompatible)
• Check only the boxes of objects that are incompatible for that
table
• Repeat the steps for the remaining aggregate table
Procedure to create @Aggregate_Aware
Step 3: Define any necessary context
• Define one context per level of aggregation

Step 4: Test the results


• Run several queries
• Compare the results
Example
@Aggregate_Aware
• The schema contains three predefined aggregate tables:
AAMONTH, AAQTR, AAYEAR

• From the example we will consider Sales Revenue to be


the only aggregate aware object in the universe

• The syntax of Sales Revenue object would be:


@Aggregate_Aware(sum(AAYEAR.Revenue),
sum(AAQTR.Revenue), sum(AAMONTH.Revenue),
sum(products.price * order_lines.quantity)

• As with any universe element, you must always test the


results in the User Module

• Run queries using the aggregated measures from the


Summary table
HANDS ON WORKSHOP
• Open the eFashion Universe

• Find out the Aggregate tables in the Universe

• Also find the aggregated objects and the levels


of aggregation

• Create couple of reports using this Universe,


use these aggregated objects in your reports
Fan Trap and Chasm Trap
Joins

A common problem in relational database schema is join


paths that return more rows than expected.

There are two types of Join paths that return too many
rows.

• Converging many to one joins. This is called a


Chasm Trap.

• Serial many to one joins. This is called a Fan trap.


Chasm Trap

The Chasm trap occurs when two “many to one” joins converge on a single
table.
Chasm Trap

You will get incorrect results if you run a query when


the following circumstances exist:

• A “many to one to many relationship” exists among


three tables in the universe structure.

• The query includes objects based on two tables both


at the “many” end of their respective joins.

• There are multiple rows returned for a single


dimension.
How do you detect a Chasm trap?

If you have two Fact tables with many to one joins converging to a
single lookup table, then you have a potential Chasm trap.
How do you resolve a Chasm trap?
Methods to resolve a Chasm Trap

Create a context for each fact table. This solution works in all cases for
BUSINESSOBJECTS universes

Modify the SQL parameters for the universe so you can generate separate SQL
queries for each measure. This solution only works for measure objects. It does
not generate separate queries for dimension or detail objects

Break the universe into multiple universes. One universe for each fact table.

This solution only applies to WEBINTELLIGENCE universes when there are


dimension objects in one or both fact tables so two SELECT statements are
synchronized and not joined
Apply a context to the Chasm Trap:
Altering the Universe SQL Parameters

Click

Click
Altering the Universe SQL Parameters
Check

The Chasm Trap query will make one query for


each measure and combine the results - correctly.
Planning to avoid Chasm traps in Web Intelligence
universes

Universe design plan could be based on the following


issues:

• One table display

• One data provider for each report.


• One Query panel

• Query can produce multi SQL, but must produce only one cube. The multi
SQL must join and not synchronize SELECT statements. This ensures that
the data is displayed correctly in the one result table that is returned
Fan Trap

The Fan trap occurs when a “one to many” join links a table which is in turn
linked by another “one to many” join.
How do you detect a Fan trap?

You cannot automatically detect Fan traps.


You need to visually examine the direction of
the cardinalities displayed in the table
schema. If you have two tables which are
referenced by measure objects and are
joined in a series of many to one joins, then
you probably have a potential Fan trap.
How do you resolve a Fan trap

If query contains only measure objects from the two tables


causing the Fan trap,
you can use the Multiple SQL statements For Each Measure
function to generate
separate SQL queries for each measure.

This solution, however, does not work for dimension


objects.
How do you resolve a Fan trap
Once you understand the two separate Select statements
from a single BusinessObjects query for resolving Fan trap
you can either:-

1. Alter the SQL parameters for the Universe


2 . Use a combination of Aliases and Contexts

NOTE: The first method is NOT recommended as it only works with


measures and will result in certain inefficiencies in processing. The
second method works every time and will not result in
inefficiencies.
To avoid placing a measure on anything other than the last table in a table path
(i.e. the table with only ‘ many ’ cardinality attached to it).
How do you resolve a Fan trap

Using Alias & Context we can solve the Fan Trap


Solution
1) Create an Alias of the Sale Table.

2) Create a join between the Sale alias &


Client table and set cardinality.

3) Set Contexts.

4) Change the SELECT clause of the Sale


Revenue object so that it refers to the Sale alias
rather than the Sale table.
Linking Universes
Linking Universes
• Linking can mean reduced maintenance.

Universe A

Universe A

Universe B
Two Approaches to Linking

• Kernel approach

• Master approach
Kernel Approach

Kernel
Kernel +

Human Resources
Kernel
Kernel
Staff Motors2000

Kernel
Kernel +
Master Approach

Master
Master -

Human Resources
Master
Master HR
and
Motors2000
Motors2000

Master
Master -
Making a Link
• Click
• and click on the Links tab  Click Add Link...

 Choose universe to link and click


Open
The Derived Universe

• The linked universe structure and objects cannot be edited in the


derived universe
• The linked universe should be treated as though they were new tables
inserted in the derived universe. The same procedure should be applied
Including Universes
• Including a Universe COPIES structure and objects to the derived
universe:

Everything
from Universe A
Universe A

Universe A

Universe B
Included Universes
• Included universes become part of the new universe

You might also like