Blog

  • Home
  • Cognos
  • A Brief on Conditional Block in Cognos 10 Report Studio

A Brief on Conditional Block in Cognos 10 Report Studio

  • (5.0)
  • | 4001 Ratings

Conditional Block in Cognos

Conditional blocks show different display results based on user interaction or parameters read in when a Report is run. They provide a creative method for presenting either the same report data in various formats or executing several completely different reports from one prompt page.

  • It is a process of blocking the layouts based on given condition
  • Create a list report with the following query items
  • Product line
  • Product type
  • Product name
  • Quantity
  • Revenue
  • From toolbox drag crosstab object drop and below the list report
  • From toolbox drag the chart object drop below the crosstab
  • In Crosstab Report
  • Drop order year on rows
  • Order month on columns
  • Quantity on measure zone
  • In Chart Report
  • Drop Product line in X-Axis
  • Order method in Series
  • Revenue in Measure
Learn how to use Cognos, from beginner basics to advanced techniques, with online video tutorials taught by industry experts. Enroll for Free IBM Cognos Training Demo!

Create a value prompt on Order year:

  • From page explorer
  • Select prompt pages
  • From insertable objects
  • Drag the page and drop in prompt page window
  • Double click on prompt page
  • From toolbox
  • Drag the value prompt object
  • Drop on prompt page
  • Next
  • From package item
  • Click on eclipses
  • Select the package item – Order year
  • Click on OK
  • Click on Next
  • Select Query1, Query2, Query3
  • Click on Next
  • Click on Finish

Create a string variable:

  • Define the following expression
  • Click on parameters
  • Drag parameter1

If (ParamDisplayvalue(‘Parameter1’))=‘2004’ THEN ‘A’ Else

If (ParamDisplayvalue(‘Parameter1’))=‘2005’ THEN ‘B’ Else

If (ParamDisplayvalue(‘Parameter1’))=‘2006’ THEN ‘C’

  • Validate OK
  • In the values window
  • Add A, B, C variables
  • From page explorer
  • Click on Page1
  • From toolbox
  • Drag the Conditional block object and drop at the bottom of the report
  • Select the conditional block
  • From properties pane
  • Select the block variable
  • Click on eclipses
  • Select string1 variable
  • Select A,B,C
  • Click on OK
  • From properties
  • Select Current Block
  • Properties
  • From Drop down list box
  • Select A
  • Select any data item in the list report
  • From Ancestor
  • Click on List
  • Drag the List
  • Drop in the conditional block
  • Again select the conditional block
  • From properties pane
  • Select current block
  • Select B
  • Select data item in the crosstab ( Select only one item not entire crosstab )
  • Drag the crosstab report
  • Drop in the conditional block
  • Again select conditional block
  • From properties pane
  • Select current block
  • Select C
  • Select data item in the chart report
  • Drag chart inside the conditional block
  • Save & run the report

Note: Scheduling can be onetime/recurring

Ex: Daily/Weekly

Frequently Asked Cognos Interview Questions & Answers

CONDITIONAL BLOCKING:

IBM Cognos report studio 1IBM Cognos Studio 2IBM Cognos studio 3IBM Cognos studio 4

CREATE A VALUE PROMPT ON ORDER YEAR:

IBM Cognos studio 5IBM Cognos studio 6IBM Cognos studio 7IBM Cognos studio 8IBM Cognos studio 9IBM Cognos studio 10IBM Cognos studio 11IBM Cognos studio 12

Explore Cognos Sample Resumes! Download & Edit, Get Noticed by Top Employers!Download Now!

Subscribe For Free Demo

Free Demo for Corporate & Online Trainings.

Ravindra Savaram
About The Author

Ravindra Savaram is a Content Lead at Mindmajix.com. His passion lies in writing articles on the most popular IT platforms including Machine learning, DevOps, Data Science, Artificial Intelligence, RPA, Deep Learning, and so on. You can stay up to date on all these technologies by following him on LinkedIn and Twitter.


DMCA.com Protection Status

Close
Close