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