Jul 31 2007

Alerters On Charts Part II

Categories: Report Techniques, Variables!, Web Intelligence Dave Rathbun @ 1:16 pm

The Challenge

In a previous post I showed a way to create the illusion of an alerter on a chart using the full client product. In this post I will reuse the same technique with a slight twist so that it works in Web Intelligence as well. If you have not already read Part I please do so first so you will be familiar with the basic steps for this technique.

Here is a summary of the steps that I used to solve this in Business Objects:

  • Create two versions of the chart: one green and one red
  • Create a variable that shows the trend of the data
  • Use the Hide Block feature of Business Objects to keep one of the charts from being displayed
  • Position both charts in exactly the same space, providing the illusion that the chart is changing colors based on the data

This is all fine… but Web Intelligence does not have the “hide block” feature. So how do I solve this issue?

Solution using Web Intelligence XI Release 2

I started out by creating the same query and the same page layout used in Part I. I ended up with two charts: one is green and one is red.

Dual charts

Since Web Intelligence does not provide a “hide block” feature I had to find something different. I experimented with different things and found that the following technique seemed to work. Instead of whining about the lack of the “hide block” feature ;-) I used a standard block filter instead. First I created the formula (which has a slightly different syntax in Web Intelligence) as follows:

=Sign([Sales revenue] Where([Year]="2003") - [Sales revenue] Where([Year]="2001"))

After creating that variable I created a block filter as shown here:

Block Filter

The filter is designed to create an empty block. However, the default behavior in Web Intelligence is to continue to show a block even if it is empty. This can easily be changed using the proper block attribute as shown here:

Show block when empty

By clearing this checkbox the empty block will not be displayed at all. This is how I can recreate the “hide block” option available in the full client products. The rest of the trick follows the same steps that I used in Business Objects. I use the block positioning options (found on the Page Layout properties) as shown here:

Block position settings

I set both the green chart and the red chart to exactly the same size and position, apply the changes, and review the results:

Final results

Summary

If you need to create an alerter on a line chart I have now shown techniques that can be used to solve that challenge in both Business Objects and Web Intelligence. Both techniques involve using two charts, a very simple variable, and then a platform-specific technique to hide a block.

Functions Used

  • Sign()

Related Posts

4 Responses to “Alerters On Charts Part II”

  1. Comment by Sree

    This article is helpful. I have one scenario where the data is coming from an object SD wks = If([LeadTime]

  2. Comment by Dave Rathbun

    Sree, your comment looks like it was cut off. You can’t use < or > from formulas in a comment as they will get interpreted as html and not saved…

  3. Comment by Ashish

    You are genius, I had a similar requirement on WEBI, but it was with a pie chart, which had only 2 values Met or Missed, it was broken down by another dimension (i.e. section expert). I could use the colour pallet Green and Red when both were present, but in case only Missed was available it would show that one as by default Green, if both Met and Missed were there then was fine Green and Red. As I got the concept I used the concept and got around it. Thanks for your tips and tricks.

    Cheers

  4. Comment by Ravi

    Hi Dave

    I’m new to your blog, this is really helpfull. Great job. I have a question from the above post. Is there any chance we can increase the thickness of the sales revenue line in the graph as we did in FULL CLIENT to improve the visibility. I checked all the oprtions in properties and couldn’t figure out. Please advice.

    Thanks
    Ravi

Leave a Reply

If you want to include formulas or code in your comment, please read my Tips for formatting comments first. Tags you can use are listed below.

XHTML: You can use these tags: <a href="" title=""> <acronym title=""> <blockquote cite=""> <code> <em> <strike> <strong> <sup> <sub> <u>

Confirm submission by clicking only the marked checkbox:

     **