Styling checkbox and radio prompts

Cognos prompts are functional, but hardly pretty. One of the many few complaints I receive is the inability to format prompts. Clients with rigid design guides are the most vocal about this, as the stark black and white frame clashes with their carefully thought out dashboard.

1 unstyled checks

The value prompt gives us some limited styling options – we can change the font, colors, size, and text direction. The tree on the other hand is almost insultingly limited. We can change the size of the prompt, and the direction of text. In neither can we change the borders or the images of the checks. So what can we do?

Fortunately we can fairly easily find the css classes governing the appearance, and use reference those in the class explorer in Report Studio. By using the developer toolbar of your choice (I’m using IE8 because some certain clients are STILL operating in the first decade of the 21st century (you know who you are)), we can quickly find the classes.

2 checkbox classes

A quicklist:
tree:                 clsTreePane pa
tree node icon:       clsTreeNodeIcon
checkbox:             clsCheckBoxList pv
unchecked:            dijitInline dijitCheckBox
checked:              dijitInline dijitCheckBox dijitCheckBoxChecked
checked descendant:   dijitInline dijitCheckBox dijitCheckBoxMixed
expand button:        dijitTreeExpando dijitTreeExpandoOpened
collapse button:      dijitTreeExpando dijitTreeExpandoClosed

Now that we know the classes to use, we have a few options to proceed. In this client, the style guide was for this project only. In theory we could have modified the style sheets for the skin, but they didn’t want to go that far. Instead, we could only use the class explorer.

The class explorer allows us to change the name of a custom class, or modify a short list of existing entries. Here lies an annoyance. If we drag in a new class, the class selector is actually going to be cls1. In order to change that, we can cut it out of the report and paste it into notepad.

3 paste class into notepad

Let’s modify this to use the image set I was given (sorry, I can show them but I can’t share them) by the design team.

<RSClipboardFragment version="2.0"><classStyle name="dijitCheckBox" label="dijitCheckBox"><CSS value="
background-image:url(../images/portal/check_blank.png);
background-position:center center;
background-repeat:no-repeat;
"/></classStyle>
<classStyle name="dijitCheckBoxChecked" label="dijitCheckBoxChecked"><CSS value="
background-image:url(../images/portal/check_full.png);
background-position:center center;
background-repeat:no-repeat;
"/></classStyle>
<classStyle name="dijitCheckBoxMixed" label="dijitCheckBoxMixed"><CSS value="
background-image:url(../images/portal/check_full.png);
background-position:center center;
background-repeat:no-repeat;
opacity: 0.4;
filter: alpha(opacity=40);
"/></classStyle>
<classStyle name="dijitTreeExpandoOpened" label="dijitTreeExpandoOpened"><CSS value="
background-image:url(../images/portal/checkMinus.png) !important;
background-position:center center;
background-repeat:no-repeat;
"/></classStyle>
<classStyle name="dijitTreeExpandoClosed" label="dijitTreeExpandoClosed"><CSS value="
background-image:url(../images/portal/checkPlus.png) !important;
background-position:center center;
background-repeat:no-repeat;
"/></classStyle>
<classStyle name="clsTreePane" label="clsTreePane"><CSS value="
border-top-style:none;
border-right-style:none;
border-bottom-style:none;
border-left-style:none
"/></classStyle>
<classStyle name="clsCheckBoxList" label="clsCheckBoxList"><CSS value="
border-top-style:none;
border-right-style:none;
border-bottom-style:none;
border-left-style:none
"/></classStyle>
</RSClipboardFragment>

There are a few things of note here. After you paste these in to the class explorer you’ll be able to modify the classes as normal. But notice I’m using the !important flag in the dijitTreeExpandoOpened and dijitTreeExpandoClosed classes. It looks like the standard image is actually resolved after the class here. !importanting (that’s a word, right?) the class ensures our style takes presedence. The opacity controls at the top is what gives the nice faded look to the checked image. Any changes to the class through the UI will wipe the non-Cognos-standard styles.

Now when we run the report, we get the fancy awesome looking results that match the style guides provided by the design teams.

4 fancy checks

report xml:
style-checks-report.txt (973 downloads)

New Cognos Maps! (Almost)

An IBM R&D team lead was kind enough to invite me for a chat at one of their labs. The team is building a new mapping solution for Cognos! It doesn’t look like it’s going to be as complicated, or have as many features as the ESRI maps, but it is far superior to what vanilla Cognos has now.

While I don’t have access to any screenshots to share here, I can describe what I was seeing. The demo was showing data pulled from the Amsterdam public transportation system. Unplanned bus stops by time of day. Unplanned could be red lights, stop signs, traffic, or even accidents. They showed a simple map of the city, with a clock plot over each area showing stops by time of day.

Creating a map can be as simple as taking an image and defining the coordinates for the corners. Apparently they support 3,500 different coordinates systems. This tool allows for the creating of internal maps too. Import your image, use a fill or polygon tool to create areas, or drop dots in certain locations. Both of which can be assigned various names for use in reports. They’re also working on a way for the software to analyze the image and try to guess specific zones. This would be incredibly useful for malls, or other places which need to track many small zones.

At the moment Cognos doesn’t have any form of map creators. The native maps (pre-RAVE), needed a third-party tool with a hefty price-tag. RAVE maps are possible, but tricky. You need to use mapping software and export is as a GeoJSON featureset. Several years back my client had a requirement to build an internal map showing the workflow of a series of manufacturing machines. Each step had to be colored based on a metric, and each machine had to have it’s grade displayed prominently next to it. As I didn’t have a MapInfo license, I needed to get tricky. Ultimately I had a solution in which each machine part was a separate image with transparency set. With each image in it’s own absolute positioned div, and all of the divs inside a singleton, a lot of conditional formatting setting the background color. This tool would have saved me a week of work.

Don’t get too hopeful about seeing this tool anytime soon though. They reminded me that they’re an R&D lab, not a software group. What they’re developing should become the basis of a new tool. We’re going to set up another meeting, and hopefully I’ll be able to get their test software installed at one of my clients. They need to know more about customer needs. How will customers use the maps? What are customers hoping for?

Feel free to leave a comment about what you would want in a new Cognos mapping tool. I’ll bring the list of comments to my next meeting with them.

A few notable solutions from the IBM Insight conference

There were many wonderful examples of ingenuity at the IBM Insight conference. From the cognitive computing teams (I <3 Watson) to the tips and tricks from the various sessions, the conference was well worth every penny. Unfortunately I can't describe every session or expo booth I attended, but here are three that are outstanding. 1. QUBEDocs
I recently had the pleasure of working with a certain organization with a “mature” TM1 environment. The culmination of years of bad practices left thousands of rules, and the stability of a house of cards. Except the cards are made of crystal and the house is in San Fransisco. That makes it sound worse than it was, but as the reporting guy there were a few days I was sitting on my hands waiting for the system to come back up. The people there were wonderful, and I honestly hope to come back there.

If only we had QubeDocs software. At the most basic level, Qubedocs is an automated documenting and tracking tool for TM1. But that hides the wonderful intricacies of the tool. At this project, like many others, we had to deal with a spiderweb of interconnecting rules and cubes. Qubedocs could very quickly parse through the rules and describe dependencies and find invalid rules.

Impact analyses, error highlighting, change tracking, documentation. These are all things that should natively part of the tool. Nothing I can say would give it the justice it deserves. I strongly recommend clicking on “See how it works” to see the videos. I’m going to see if I can get one of my regular clients to buy a license to give me the chance to play with it.

2. ITGain
ETL is one of those things that I can do, but it’s never sexy. ITGain’s software SpeedGain is ETL monitoring software. In their demo, they showed a simple dashboard displaying the state of server, CPU time and sort operations. In ETL proceses, high sort means bottlenecks. CPU means the ETL is doing something, anything else means you’re sitting there twiddling your thumbs.

speedgain dashboard

A mature environment might have dozens or more processes. How can you identify which module is causing the bottleneck? SpeedGain will allow you to drill down to find the module in question, or even the individual SQL statements. It will list the individual statements by executions and cpu time.

speedgain SQL Statements by CPU time

Sort operations, as we all know now, are often caused by poorly designed indexes. So SpeedGain will actually recommend one. After implementing the suggestions the runtime of the slow ETL module is reduced dramatically. Since the statements didn’t need to scan the table, we could see the sort operations drop to almost nothing, with CPU time increasing as it has data to work with.

speedgain SQL analysis

At the moment they are supporting DB2 and Oracle.

3. Miami-Dade County Cognos Audit
The Miami-Dade County is a large user of Cognos. The reporting for many services have been folded into their implementation. They also have internal and external facing Cognos setups, meaning that we can actually view many reports. Because of their immense set up, and thousands of named users, they need to have a robust security and audit system set up. The audit also serves as proof of use to justify budgets and to encourage moving more services to their systems.

By default the Cognos audit reports are fairly ugly and slow. When dealing with thousands of users, and even more reports, just opening the prompt page can be an exercise in patience. The reports here are designed to be fast dashboards.

The biggest issue I have with this solution is that is was built natively against Oracle. Adapting it to SQL Server or DB2 is possible, but takes some work.

I’ve attached the solution with their permission below.
Miami-Dade County Audit Reports (747 downloads)