Sunday, January 24, 2016

What is Framework Manager?

IBM Cognos Framework Manager is a metadata modeling tool that drives query generation for IBM Cognos software. A model is a collection of metadata that includes physical information and business information for one or more data sources.


When you work in IBM Cognos Framework Manager, you work with a number of objects that are contained in a project.


Projects:

A project contains a model, namespaces, packages, data sources, and related information for maintaining and sharing model information. A single project can span many data sources or tables.
An IBM Cognos Framework Manager project displays as a folder that contains a project file (.cpf) and the specific .xml files that define the project. The files in a project folder are unique to each project. The project and its associated files are contained in a project folder.

Models:

A model is the set of related query subjects and other objects required for the related reporting application.

Namespaces:

A namespace uniquely identifies query items, query subjects, and other objects.

Packages:

A package is what is actually published to the IBM Cognos BI server and is used to create reports, analyses, and ad hoc queries.

Query Subjects:

A query subject is a set of query items that have an inherent relationship. In most cases, query subjects behave like tables.

Query Items:

Query items are contained in query subjects. For example, a query subject that references an entire table contains query items that represent each column in the table.

Sunday, January 17, 2016

How to display blob images in Cognos Reports

Overview

One common requirement for reports is to display images store inside the database. When adding these tables and columns from database to Cognos Framework Manager Model, the image column are represent as ‘BLOBs’ inside the model and package.

When BLOB fields are use in Cognos Report Studio from the published package, none data is displayed.

Cognos does not support reporting ‘BLOB’ data types!

The Idea

The idea to work around this issue is to add a asp page that will get record information from the Cognos report, retrieve the image file from the database and return to Cognos as html displaying the actual image to be use a URL information in a image object in Cognos Report Studio.

Considerations / Impacts / Challenges

       Security: Security will have some limitation with this approach, however, security could be apply in many different ways according to each environment and requirements.

Observations

Diagram:




ASP Page Code (sample)




<% @language=VBScript %>
<%
Dim ONES
Set ONES = Server.CreateObject("ADODB.Connection")
ONES.ConnectionTimeout = 15
ONES.CommandTimeout = 30

ONES.Open "Provider=SQLNCLI; Server=WINS-DATABASE\WINS2012; Database=name; Uid=user; Pwd=password;"

Dim rs

Set rs= ONES.execute("select imagecolumn from imagetable where id='" & Request.QueryString( "attach_id" ) & "'" )

If rs.eof=false then
Response.ContentType = rs(1)
<!--Response.Flush -->
Response.Buffer = True
Response.BinaryWrite rs(0)
Response.End
End If
rs.close
ONES.close
Set ONES=nothing
%>

ASP Page Location

Any location in the network that can be reach by the Cognos Report
Image Object in Report Studio: Change the URL property for the object to point to the asp page location


Hope this really helps. Please don’t forget to leave your comments and questions below. And keep Thinking Cognos :)

Tuesday, January 12, 2016

Questions that helps troubleshooting a slow running Cognos report


I think these set of question will allow you to find the issue when gathering information from end users about a report in the Cognos environment that is not performing as expected.

Hope this helps many. Please enjoy:


  • Has the report always been slow or did it recently become slow?


If it recently became slow, can you identify an event that occurred just before the report began to run slowly? Events could include changes to configuration settings, changes to tuning settings, a recent upgrade where your previous settings have not been applied, an introduction of firewalls or proxies, changes to existing firewalls or proxies, changes to virus scans on temp directories, or temporary table space restrictions on the database. This event could have caused the change in report performance.

  • Is the performance slow for all reports or just one report?


If all reports are slow, the issue may be due to your environment or database. If all reports from a specific package are slow, the issue may due to the model design. If just one report is slow, the issue may be due to a specific report element.


  • How many queries does your report contain?


The number of queries on the report will proportionally affect the report execution time.
Does the report run slowly for everyone, or just for one user?
If the report runs slowly for just one user, the issue may be due to something in that user's environment, such as virus scanning, page file size or location settings, or their location on the network.


  • Is the report burst or run often by many people?


If many people are running the same report at the same time, you may need to scale your environment or consider using dispatcher routing rules to direct all requests for a specific package or group of users to a specific server or server group.


  • Do your queries require local processing?


The following report elements require local processing: crosstabs and charts, master relationships, unions or joins, multiple fact queries, bursting, and non-vendor specific functions. Local processing requires the IBM Cognos server to compute operations on the result set returned by the database, which can impact the SQL execution time.


  • Have you reviewed the logs in the c10_location/logs directory and the audit logs?


They may help you identify the source of the problem. Monitoring your processes, such as the Java and Business Intelligence bus processes could also identify excessive memory use.


  • Have you recently upgraded?


Ensure that any tuning settings that were applied to your previous installation are applied to the new environment. Ensure that your models have been verified, upgraded, and republished. Verify that the IBM Cognos Framework Manager governor that allows enhanced model portability at runtime is not enabled. Depending on your upgrade method, you may also need to open and save the reports again after upgrading.

Wednesday, January 6, 2016

Tips to improve Cognos Report Studio reports Performance

Tips - may help improve report performance

Improving Cognos Report performance is always a challenge. Here are a few items that will allow you accomplish the task:
  • Change the order in which items are queried from the database.
  • Create sections without creating master detail relationships. Share queries between lists and repeaters.
  • Review SQL generated by report and queries.
  • Avoid using functions with limited support, as indicated by the quality of service indicators.
  • Use Select & Search prompts instead of value prompts if your list of prompts is long. 
  • Provide your own prompt values in a prompt to avoid accessing the database. 
  • Suppress null cells using filters. 
  • Set page breaks without creating master detail relationships. 
  • Do not put filters on non-identifiers.
  • Use database functions when possible.
  • Use fixed width objects in PDF reports by setting their Size & Overflow properties.



Thank for reading... let me know if you nee additional information on any of these.

:)

Tuesday, December 10, 2013

Automate Cube in Cognos Transformer 10

Overview:

Automating Cubes refreshing should be an easy task, however most of the documentation and information available online is not completed or it is ambiguous and let much room for problems. We are writing this quick reference guide with the intention of more than step by step instructions, to be an easy way to “understand” how Transformer and the Power Cubes deployment work for automation, allowing you to make appropriate changes according to any unique requirements.

Assumptions:

  • You already have a valid Transformer model fully operational and created the PowerCube in Transformer

In this sample:

  • Model file: C:\Users\someuser\Documents\Transformer\Models\tt.pyj
  • PowerCube file name: lolo.mdc
  • Deployment location: C:\Users\someuser\Documents\Transformer\DeploymentLocation


--------------------------------------------

Steps:

Cube Properties

  • Open Transformer model 
  • Right click on Cube and display cube properties and select “Deployment” tab 
  • Change “Deployment strategy” to “Copy to available location, then activate” 
  • Change “After building the cube” to “Automatically copy and activate” 
  • Add new “Deployment location” (note: same location will be used in “Data Source Windows location” and different location from Cube effective path) 
  • Select “Enable automatic PowerCube deletion” and set the Maximum number of old cubes to keep as needed. 

  • Update the “Windows location” in “Data Source” tab to point to the right deployment location 

Insert auto logon Signon

  • From the menu bar select “View > Signons” 


  • Right Click inside the Signons window and Click “Insert Signon…” 


  • Add Signon information required for the cube automation. Click ‘Ok’ and confirm the password. 



  • Save the model 
  • Exit Transformer

Command Line (Cube Automation)


  • Open command prompt 
  • Navigate to Cognos Transformer installation /bin folder 
  • Type and run the following command line: 
cogtr -n2 -c -glolo -s -pC:\Users\someuser\Documents\Transformer\Models\tt.pyj

  • cogtr: Start the transformer application
  • -n2: Run the application in batch mode and hidden
  • -c: Load the model file, generates categories, and create the cube
  • -g: Copies newer version of cube to deployment location and activate the new version
  • -s: Saves the model

  • Check for 3 new items (2 files and 1 folder) added to Deployment location 
  • The .mdc file in this location is the one that should be used in Data Source Connection (cognos administration) 


Publish Data Source and Package

  • Open Transformer model 
  • Right Click the PowerCube and select “Publish PowerCube as Data Source and Package…” 


  • Follow wizard instruction on screen 
  • Click ‘Finish’ 
  • Save and close the model