Anyone know how to harvest/export Cognos tool tip defs?

This forum is the beginning of our inclusion of Cognos users to have their own place to go within our community. It is said the ETL and BI don't intersect, but as IBM integrates their platforms, there are less lines of demarcation between the two.

Moderators: chulett, rschirm

Post Reply
deboots
Premium Member
Premium Member
Posts: 71
Joined: Thu Feb 23, 2012 11:15 am
Location: Portland, OR

Anyone know how to harvest/export Cognos tool tip defs?

Post by deboots »

We are getting ready to implement InfoSphere Business Glossary and link it to Cognos. As most of you know, we can easily change the Cognos configuration to use BG as the source for definitions. However, there have been some implementations through the years where developers embedded term definitions within the Cognos packages using tooltips/screentips. It's difficult to assess whether these are being used. I don't want to remove functionality from the business. I'd like to be able to harvest this data in some way. If I could access it easily I could then format it to batch load it into the Business Glossary.

Anyone know how to get this tooltip / screentip data out of Cognos?
Anyone know an easy way to scan and determine where tooltips/screentips exist within Cognos?

Thanks!
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

After you've imported the Cognos BI report definitions, does perhaps the bi2bg utility pick up terms defined in tooltips?
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
vmcburney
Participant
Posts: 3593
Joined: Thu Jan 23, 2003 5:25 pm
Location: Australia, Melbourne
Contact:

Post by vmcburney »

This is easier of version 8.7 than earlier versions. First you run the Metadata Asset Manager to import the Cognos metadata from Cognos into the Information Server. The Metadata Asset Manager has a wizard and shows the bridge parameters for your import. You should test it out with one smaller cognos folder or package first to get it working.

Next run the aforementioned bi2bg option for istools on the Information Server. This will convert the Cognos model into a Business Glossary - it should come through with the report headings and the tooltips.
bi2bg Documentation.

Both processes may fail if you try it on an entire Glossary model so I would trial it on a subset first.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Indeed it can fail even on a medium sized Cognos model.

One way we have had to implement is to replace the 32-bit JVM that installs with the product with a 64-bit JVM provided by IBM support. No more java.lang.OutOfMemory errors (thus far)!
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
deboots
Premium Member
Premium Member
Posts: 71
Joined: Thu Feb 23, 2012 11:15 am
Location: Portland, OR

Finally just wrote a Python script to parse the Cognos FM

Post by deboots »

Thanks for the documentation link, Vince. However, we still didn't find this to be very easy - even on 8.7. We were able to import the BI model into the repository - though had to guess at what was needed on some of the prompt screens. However, could never get the bi2bg parameters on istools to run.

One of the programmers did however write a python script that pulls the tool tip text into an Excel file along with the context/path. Since I wanted the Stewards to review those prior to load - that gives me what I really need (since I can now reformat that into the .csv import format that BG really wants).

I still want to be able to use the bi2bg process - but at this point may just wait to corner or bribe someone at IOD to walk me through it. :wink:
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

I'm running bi2bg successfully at my current site (finishing there today) so let's catch up at IOD.

We've scripted it to run out of a third party scheduler, but the script itself is very straightforward. You'll notice we're running on Windows, so it's a BAT file, but there's hardly any logic to it. In UNIX use $? rather than %ERRORLEVEL% and test -f rather than exist and you should be very close.

Code: Select all

@ECHO OFF
REM Identify business terms in previously imported Cognos assets.
REM Authentication information is in local file "E:\Data\Authfile\ServiceBGAdmin.txt" (password is encrypted).
REM Configuration file is "E:\Scripts\Cognos\bi2bgconfig.ini" (supplied by IBM and edited).

:processing
REM Domain name uses DNS entry to mask real server name
set domainName=ATOBusinessGlossary
REM Pathname of istool command
set istoolCmd=E:\IBM\InformationServer\Clients\istools\cli\istool
REM Pathname of authentication file
set authFile="E:\Data\Authfile\ServiceBGAdmin.txt"
REM Pathname of bi2bg configuration file
set configFile="E:\Scripts\Cognos\bi2bg_config.ini"
REM Pathname of log file
set DateTag=%date:~-4,4%%date:~-7,2%%date:~0,2%
set logFile="E:\Scripts\Cognos\logs\bi2bg_%DateTag%.log"

echo.Started %date% %time% 
if exist "E:\Scripts\Cognos\bi2bg_preview.csv" DEL "E:\Scripts\Cognos\bi2bg_preview.csv" && echo."E:\Scripts\Cognos\bi2bg_preview.csv" deleted.
if exist "E:\Scripts\Cognos\bi2bg_duplicate_terms.csv" DEL "E:\Scripts\Cognos\bi2bg_duplicate_terms.csv" && echo."E:\Scripts\Cognos\bi2bg_duplicate_terms.csv" deleted.
echo.
echo.Command being executed:
REM Process business terms in imported Cognos assets.
REM To create a preview file only, use configuration file bi2bg_config_previewonly.ini; to actually populate the metadata
REM repository, use configuration file bi2bgconfig.ini.
echo %istoolCmd% glossary bi2bg -cfg %configFile% -domain %domainName% -authfile %authFile% -verbose -log %logFile%
%istoolCmd% glossary bi2bg -cfg %configFile% -domain %domainName% -authfile %authFile% -verbose -log %logFile% 
set result=%ERRORLEVEL%
echo.Finished %date% %time% - status = %result%

if %result%==0 echo Processing of Cognos terms complete.  Details in "istool_glossary_bi2bg_%DateTag%.out".
if %result%==0 goto finish
echo. Processing of Cognos terms failed. See "istool_glossary_bi2bg_%DateTag%.out" for details.

:finish
The configuration file is not too tricky. Here's the one I put in place. The structure is well documented in the Information Center.

Code: Select all

# Specifies the names of the models to be processed.
ModelsToProcess = *

# String to be displayed in the Example attribute of the term in Business Glossary.
MemberTypeRegular = Dimension
MemberTypeMeasure = Fact

# If TRUE, BI collection members are assigned to the terms that are created from them.
ClassifyMemberTargetSource = TRUE

# List of categories to exclude.
CategoriesToExclude = test

# Specify the merge option to use when the categories and terms are imported.
# MERGE_SOURCE_BIAS merges the asset and overwrites existing attributes that cannot be merged.
# MERGE_TARGET_BIAS merges the asset and ignores imported attributes that cannot be merged.
MergeOption = MERGE_SOURCE_BIAS

# If TRUE, sets the IsModifier attribute of all imported items to "Yes".
IsModifier = FALSE

# Specify the Business Glossary status attribute of all imported terms.
Status = ACCEPTED

# Type specifies the Business Glossary type attribute of all imported terms.
Type = NONE

# Specify whether to create a Business Glossary preview in a CSV file or in the log file.
# If a preview is selected, nothing is written into the Business Glossary itself.
# If a preview is not selected the other three settings in this group are ignored.
CreateBusinessGlossaryPreview = FALSE
BusinessGlossaryPreviewFormat = CSV
BusinessGlossaryPreviewCSVFilePath = E:\\Scripts\\Cognos\\bi2bg_preview.csv
FirstRowColumnNames = TRUE

# Category under which to store terms migrated from Cognos assets by the bi2bg utility.
ImportToTopCategory = TRUE
TopCategoryName = Enterprise Reporting

# Handling of duplicate terms.
CheckForDuplicateTerms = TRUE
DuplicateTermsFileName = E:\\Scripts\\Cognos\\bi2bg_duplicate_terms.csv
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
eostic
Premium Member
Premium Member
Posts: 3838
Joined: Mon Oct 17, 2005 9:34 am

Post by eostic »

Hi Ray...

Thanks......though I'm not certain that bi2bg picks up all of the possible description properties that may have originated in FrameWorker Manager for a particular Package that you've imported.... can you confirm which of the properties you are successfully getting for each query item? Description? Screen Tip? other?

...I've often been doing other things like exporting the Framework Manager as XML, and then pulling out various bits into a spreadsheet or csv, as deboots suggests.

Thanks.

Ernie
Ernie Ostic

blogit!
<a href="https://dsrealtime.wordpress.com/2015/0 ... ere/">Open IGC is Here!</a>
eostic
Premium Member
Premium Member
Posts: 3838
Joined: Mon Oct 17, 2005 9:34 am

Post by eostic »

Hi Ray...

Thanks......though I'm not certain that bi2bg picks up all of the possible description properties that may have originated in FrameWorker Manager for a particular Package that you've imported.... can you confirm which of the properties you are successfully getting for each query item? Description? Screen Tip? other?

...I've often been doing other things like exporting the Framework Manager as XML, and then pulling out various bits into a spreadsheet or csv, as deboots suggests.

Thanks.

Ernie
Ernie Ostic

blogit!
<a href="https://dsrealtime.wordpress.com/2015/0 ... ere/">Open IGC is Here!</a>
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

I have finished at that site, so can not confirm or deny whether all properties are received for each query item - nor even if they use tool tips at all.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Post Reply