Beruflich Dokumente
Kultur Dokumente
Copyright
Copyright 2008 Cognos ULC (formerly Cognos Incorporated). Cognos ULC
is an IBM Company. While every attempt has been made to ensure that the
information in this document is accurate and complete, some typographical
errors or technical inaccuracies may exist. Cognos does not accept
responsibility for any kind of loss resulting from the use of information
contained in this document. This document shows the publication date. The
information contained in this document is subject to change without notice.
Any improvements or changes to the information contained in this document
will be documented in subsequent editions. This document contains
proprietary information of Cognos. All rights are reserved. No part of this
document may be copied, photocopied, reproduced, stored in a retrieval
system, transmitted in any form or by any means, or translated into another
language without the prior written consent of Cognos. Cognos and the
Cognos logo are trademarks of Cognos ULC (formerly Cognos Incorporated)
in the United States and/or other countries. IBM and the IBM logo are
trademarks of International Business Machines Corporation in the United
States, or other countries, or both. All other names are trademarks or
registered trademarks of their respective companies. Information about
Cognos products can be found at www.cognos.com
This document is maintained by the Best Practices, Product and Technology
team. You can send comments, suggestions, and additions to
cscogpp@ca.ibm.com .
Contents
1 INTRODUCTION ............................................................................................ 4
1.1 PURPOSE ............................................................................................................4
1.2 APPLICABILITY .....................................................................................................4
2 IBM COGNOS PLANNING AS A DATA SOURCE .............................................. 4
2.1 DATA ACCESS ......................................................................................................4
2.2 OBJECTIVES: .......................................................................................................5
2.3 WHAT DOES THE EXTENSION PROVIDE?........................................................................5
2.4 PUBLISHING THE CUBES ..........................................................................................7
2.4.1 Table-only or View Layout. .................................................................................7
2.4.2 Cube selection...................................................................................................7
2.4.3 Dimension for Publish ........................................................................................8
2.4.4 Which e.List items? ............................................................................................8
2.4.5 Table Options....................................................................................................9
2.5 GENERATED FRAMEWORK MANAGER MODEL EXTENSION ...................................................9
2.6 BASE MODEL AND USER MODEL............................................................................... 11
3 CUSTOMIZING THE FRAMEWORK MANAGER MODEL................................. 12
4 DRILLING TO CONTRIBUTOR ..................................................................... 12
5 PRESENTING CONTENT IN CONTRIBUTOR ................................................ 16
5.1 SUMMARY: ........................................................................................................ 16
5.2 OBJECTIVES: ..................................................................................................... 16
5.3 CREATING AND CUSTOMIZING PAGES ........................................................................ 16
5.3.1 Creating the Page ............................................................................................ 16
5.4 USER SPECIFIC CONTENT CONDITIONAL BLOCKS ........................................................ 19
5.4.1 How do they work?.......................................................................................... 19
1 Introduction
1.1 Purpose
This document is designed to introduce attendees to the improvements in reporting
from IBM Cognos Planning and IBM Cognos 8 BI, focused on techniques to improve
presentation, navigation and enrich content. Demonstrations use a combination of
IBM Cognos Planning 8.1 and IBM Cognos 8 version 8.2
1.2 Applicability
IBM Cognos Planning 8.1 and IBM Cognos 8 version 8.2
Publish
Plan Data Container
CDS Reports
Although the Contributor Data Server provides easy access to live data, published
data with a Framework Manager model will provide the most scalable, rich, and
robust reporting. This section will discuss the publish process, the metadata
delivered by the Generate Framework Manager model extension, and what you can
do to improve the model.
2.2 Objectives:
Upon completion of this section, you will have successfully generated and modified a
model from published data using the Contributor extension. You will understand the
impact of Contributor model changes, and how to update and synchronize your FM
model.
Dimensional over Relational Model (i.e. can be used for member/level based
reporting out of the box)
Sort Items built in (No need to define sort order for months, accounts, etc)
Security filters are built in based upon the e.List security in Contributor.
Physical View & Business View with Star Schema Groupings and appropriate
joins
The view publish exists only to support customer reporting environments which
previously consumed the view schema. Data in the view publish layout is published
as Varchar(8000) (or CLOB, or Varchar2(4000)) and does not act as a source for the
Framework manager model generated from Contributor. It is likely that this layout
will be deprecated in the future, and so should definitely not be used for new
reporting implementations. Specific benefits to using the table publish are:
table and column names that are restricted only by their respective database
limits
This is important but often overlooked step in the publish process. Ensure that you
select cubes that will actually be consumed in the reporting environment. There is
often a great deal of disparity in volumes between report worthy data and model
data, particularly when specific summary cubes already filter out key items for
reporting. Attention up front to the reporting needs will save lots of time when
publishing the data.
The most common dimension for publish to use is the one that will have formats and
calculations, or the number one D-List in the cube. By using this dimension, you can
take advantages of the following features:
Member Functionality you will not be able to use member functions like children,
sibling, etc on the dimension you choose (for example, e.List, Months, Product).
Data Type Conformance your data can be difficult to manipulate, as your columns
will all be formatted as varchar, or presented sparsely with a separate column for
each type.
One thing about the e.List that makes it easier to manage than other dimensions
when reporting is that it is the one dimension that we can be certain has a simple
hierarchy. There is no need, in a DMR or OLAP model, to publish the total levels of
this dimension, so unless you are using only a relational model from the application,
choose the Select All Planners button.
Include Rollups
By deselecting include Roll-ups, all simple aggregations will be removed and data can
then be summed by the reporting tools. This can drastically reduce publish time
provided the reporting tool used is recreating these sums.
Off by default, and only really useful for publish databases which are the source for
data warehouses which need to update balances. This can setting can have a large
impact on performance in models that are sparse.
Include User Annotations creates an an_cube table with any annotations that have
been added by the users to individual cells tab and model annotations are already
published separately to the annotation object table.
Include Audit annotations adds audit information for each cube to the same an_cube
table mentioned above.
The extension also includes several options to allow you to customize the generated
output.
Firstly, you can decide which cubes you wish to include in the model. If you have
followed the previous advice of only publishing cubes which you intend to use for
reporting, you will likely select all cubes.
Secondly, you will choose which types of query subjects to create and include in the
model.
Unformatted Lists:
These are based on the it_dimensionname tables, and include information about the
dimension without hierarchies. These can be used quickly and easily to create a
relational model, and for several other techniques discussed later. You will likely
want to include them.
These are based on the sy_dimensionname tables, and include hierarchy information
similar to the complete hierarchy tables, with the key difference being how the
hierarchies are constructed to handle complex calculations rather than simple sums.
A comparison for the following D-List demonstrated a key difference between the cy
and sy tables:
CY table
SY table
In the above example, the complex calculated parent has been moved to the root in
the SY, as has its orphaned constituent and calculated constituent. Only 1 additional
level remains for the simple children of a constituent. This ensures fidelity for the
complex calc when used as a reporting source, but presents a flatter hierarchy.
The user model is created from the base model through importing (the extension
does this for you the first time). After the base model is imported, each change you
make is recorded in a script that can then be played back if you need to make the
changes again after importing a fresh copy of the base model.
When there are changes made in Contributor (additional cubes published, dimension
names changes, levels added to a dimension, etc) and you republish the data, you
will also need to update the base model (using the extension) and synchronize the
user model.
Out of the box, the model you have can now be used with any studio, provides a
secure and scalable source for reporting and analysis, and can satisfy the needs of
most report authors. So what work is left to do? That depends largely on how you
use the model when used purely for member based Analysis and reporting, you
may not require any changes. If however, you plan on using it for level based
reporting and analysis, you will likely want to rename many of the generated level
names, and possibly the measures as well. Contributor, not using the concept of
levels, provides you with no facility to name the levels that it will generate for you
during the publish process.
4 Drilling to Contributor
So, youve created a rich, full content reporting and analysis solution for your
customer that has everything Business Intelligence can provide to help make
understanding the plan easier and gathering and executing the plan more efficient.
But there is something missing. The customer can see how his/her current plan
compares with previous plans; knows the top 10 variances between them, and the
reasons why, and is alerted when someone exceeds the thresholds that have been
defined. To change the plan however, he or she must log in to Contributor and find
the numbers that have to be changed.
Tasks:
3. Name the calculation based on the level it pertains to (to simplify adding it to
that level later on).
An example follows:
'http://vclassbase/cognos/contributor/planning10.asp?appid=sales&multi
node=0&item=' + [Model].[Unformatted list eList].[Dimension GUID] +
[Model].[Complete hierarchy eList].[Level 0 eList ID]
6. Repeat for each level in the elist hierarchy (if you wish to drill from parent
level data directly to contributor
For example:
Regions
'http://vclassbase/cognos/contributor/planning10.asp?appid=sales&multi
node=0&item=' + [Model].[Unformatted list eList].[Dimension GUID] +
[Model].[Complete hierarchy eList].[Level 2 eList ID]
Salespeople
'http://vclassbase/cognos/contributor/planning10.asp?appid=sales&multi
node=0&item=' + [Model].[Unformatted list eList].[Dimension GUID] +
[Model].[Complete hierarchy eList].[Level 3 eList ID]
8. Click on the Contribution Hierarchy and then click the Dimension Map tab.
9. Drag each level based drill into the dimension map in the appropriate location
(based on the level names you used when you created the drill calculations).
When prompted, select to use No Role.
11. Using report studio, create a new report in the style of your choice from the
toolbox, drag a hyperlink object to the report and then add your drill
By default, these
hyperlinks will open in
the same window as the
report for added
usability; insert an html
item from the toolbox
with the following text:
<base target="_blank">
This will open a new
window each time you
click the hyperlinks.
<base
target="anyname">
Will open a new window
the first time and will
reuse for subsequent
clicks.
12. When you run the report and click the URL, the following window should
open:
5.1 Summary:
Throughout the course, weve developed attractive, rich content reports, analysis,
and events that add tremendous value to consumers. The focus of this section will
be on delivering this content in the most meaningful ways possible. This includes
merging some of the content to a dashboard, presenting it to end users while they
are navigating contributor, and building that content in the context of the particular
consumer.
5.2 Objectives:
Upon completion of this module, users should understand how to create pages,
incorporate multiple content sources, make the content user specific, and present it
in Contributor.
IBM Cognos Connection provides excellent facilities for users to create their own
pages with content specific to their needs. These pages can be used as dashboards
that drive rich content to a single location, without having to navigate though reports
and analysis to find what they need. The fact that these pages are independent of a
package or query means that this is one location where we can combine workflow
information with live data, so that users can not only see what the current plan is
shaping up to be, but also how complete it is. We will explore this functionality and
see what it can provide to the planning process.
Pages are very easy to create in IBM Cognos Connection the hardest part is
deciding what to put on them. On the toolbar, click the New Page icon.
You then need to decide if you want to use multiple columns on the page. If we are
defining pages for the Instructions pane in Contributor web, keep in mind that real
estate is limited already by other items in the Workflow page. If however, you
designing these pages for Cube Specific help, or for IBM Cognos Connection itself,
you can use multiple columns without drastically affecting appearance.
The next set of options is very important if we want to use this page for Contributor.
Adding a title can be nice, but when the report renders in Contributor, it usually
looks cleaner without it. Borders, the toolbar, and edit buttons should definitely be
removed in the final product, but not yet removing them now will prevent you from
being able to add the content.
To bring these pages to life, we can present them in Contributor, designed for
specific users and cubes. First, well take a look at how we can make these pages
dynamic for each user.
Have you ever been asked to show a separate Instructions pane depending on the
user or the e.List review level? Although Contributor provides static presentation in
the instructions and cube help, Report Studio has some excellent controls for
providing exactly this functionality, and when we combine this with the next
technique for using iFrames or redirect links in Contributor, we can deliver exactly
what users want to see, right in the Workflow Instructions pane. To design user
specific content we will use conditional blocks.
5.4.1 How do they work?
Conditional blocks manage what is displayed based on the value of a variable that
we define. In our case, we create a calculation that uses a session variable called
account.defaultname to return the current user that is running the report. The block
checks the value of this variable and only display the items that are associated with
that condition.
1. Open Report Studio using the Sales Plan Generated package and create a New
Blank Report.
2. Open the Query Explorer, click Queries, and drag a new Query from the
toolbox to the query window.
3. Double-click Query1, and drag a Data Item from the Toolbox to the Query.
4. Double-click Data item and enter the following expression (exactly, and it is
case sensitive):
#sq($account.defaultName)#
5. Set the Name property of the data item to User Click the Page Explorer
and click Page 1.
6. Click the Page Body to highlight it, and then select the ancestor button to drill
up from the Page Body to the Page:
9. Highlight the Conditional Block and browse on the property Block Variable.
10. From the Block Variable Window, select New String Variable.
11. Enter the name Username, click Add, and type the user name exactly as it is
defined (these are case sensitive as well)
12. Repeat for the items below until your New Variable window appears with all
of the appropriate users. An example follows:
This creates a block for each variable you enter blocks will hold report
objects that only display when the variable we define matches.
14. The Report Expression dialog appears drag User to the Expression
Definition Pane.
15. Click OK, and then in the Properties pane, change the Current Block value to
whichever user you want to define content for (Other will be the content for
any user not named explicitly in the conditional style)
16. Placing objects within the conditional block will allow you to design reports
specifically for any of the users youve named, and to add default content for
others. You can switch the current block variable at any time to build for each
user, and you can open the conditional explorer to add others at any time.
Remember that security filters will manage the data being exposed as well, so
you may want to query all members and let security filter the users view rather
than trying to guess which members are visible for which users.
<html>
<body>
<div>
<iframe src="the url of your report"style=width:1100px;
height:800px"></iframe>
</div>
</body>
</html>
To get the url of a report, click the report properties, then click View the
search path, ID and URL copy and paste your url to the appropriate location
in your Contributor Help Text or redirection snippet.
You can use the same techniques for each cube in the model as well as for
the Instructions frame in the Workflow page.
If your report content includes drill hyperlinks, ensure that you add the html
to open those links in a new window: <base target="_blank">
This technique works well for pages also define an entire dashboard for
your users and deploy it within Contributor
If you wish, you can remove header content from the page by appending the
following to the report url:
&ui.header=false
Nodeguid
Stateid
StateDateTime
DataDateTime
Join Nodeguid to the dimension table of your choice (it_table is an easy start) using
a 1:1 -> 1:1 relationship from nodeguid to item guid.
Note that this is a cross database join, and will require the package to allow limited
local processing (on by default) and may slow performance over models with a large
elist dimension.
CASE [Model].[nodestate].[stateid]
WHEN 0 THEN 'Not Started'
WHEN 1 THEN 'Incomplete'
WHEN 2 THEN 'In Progress'
WHEN 3 THEN 'Ready'
WHEN 4 THEN 'Locked'
END
To translate state ids to images (replace contributor server url with you own):
CASE [Model].[nodestate].[stateid]
WHEN 0 THEN 'server url/IMAGES/WORKFLOWICONS/Normal/1nsnormal.gif'
WHEN 1 THEN server url /IMAGES/WORKFLOWICONS/Normal/2incnormal.gif'
WHEN 2 THEN server url /IMAGES/WORKFLOWICONS/Normal/3wipnormal.gif'
WHEN 3 THEN server url /IMAGES/WORKFLOWICONS/Normal/4readynormal.gif'
WHEN 4 THEN server url /IMAGES/WORKFLOWICONS/Normal/5locknormal.gif'
END
IF ( [Model].[nodestate].[statedatetime] = '0000-00-00T00:00:00.000+00:00' )
THEN ( NULL )
ELSE (cast_timestamp ( substring ([Model].[nodestate].[statedatetime] , 1, 10) + ' '
+substring([Model].[nodestate].[statedatetime] ,12,8)))