Cognos cross tab percentages

 

How to get percentages in cognos cross tab

I need to calculate % for count distinct value. to do this in the query we need 3 data items.
data item 1 – count (distinct item_id) . solve order 1
data item 2 – count(distinct item_id for report) . solve order 2
data item 3 – data item 1/ data item 2

use data item 3 in your crosstab and format it as percentage.

 

Cognos – pass prompt value to SQL query

To pass a prompt value say – “p_reportdate” to sql query then syntax is as below
select * from table1 where table1.date =  #prompt(‘p_reportdate’)#

if the prompt- “p_name” is multi select then
select * from table2 where table2.name in (#promptmany(‘p_name’)# )
 

 

few other related articles
http://www-01.ibm.com/support/docview.wss?uid=swg21341148

How to dynamically name tabs in excel 2007

When we use page set, report output in excel will have tab names as page1, pag1_2, page1_3, so on..

If you want to display this tab names by report section names then follow below configuration methods.

In cognos configuration settings at Report service for each dispatcher add below advanced settings

Parameter column, type-  RSVP.EXCEL.PAGEGROUP_WSNAME_ITEMVALUE

Value column, type-  TRUE

Source: https://www.ibm.com/support/knowledgecenter/SSEP7J_10.2.2/com.ibm.swg.ba.cognos.ug_cra.10.2.2.doc/t_ug_cra_adv_prop_name_worksht_tabs_excel2007.html

 

Page set in Cognos

  1. Create page1
  2. In page1 create a list report say list1 and query1
  3. Now go to page explorer, create a “page Set”
  4. Drag page1 to detail pages
  5. select “page set”. change query to query1.
    At “grouping & sorting” drag required column you would like to group data on.
  6. Run the report. Pages should be separated based on group by element.

Youtube video –

cognos drill through from a button/URL link

Had a situation where I need to develop a detail report for a dashboard based on the prompts selected in that dashboard.
Dashboard had multiple summary lists/crosstabs/charts
below are high level steps.

Solution:
1. develop a detail list report based on the same prompts.
2. At master report

  1. create a singleton (on the dashboard where you want to see the url)and say you assigned it to query – q_detail.
  2. Create a data item say “Detail data” and with value “click for detail data”
  3. now add this data item to the singleton you created.
  4. select the data item in the singletom and select drill-Through definitions.
  5. select required report and other options. At parameters click on edit sign and use
  6. “Pass parameter value” and select associated prompt name.
  7. click ok.

now when you run the summary report you should see a link “click for detail data”