Tuesday, 11 November 2014

COGNOS: CHANGING THE DEFAULT COGNOS PORT

Most of the clients do not want to use the default port number 80 to use due to some security concerns. We can change the port 80 to desire number in Cognos. Here are the steps:

Cognos Configuration :
  1.  Open Cognos configuration.
      2.   Edit gateway URI and Controller URI for gateway , replace port no. 80 with 8081.

Configure the IIS to use port 8081 :
 

1.      On the Windows desktop, click Start, click Administrative Tools, and then click Internet Information Services (IIS) Manager.
 
2.      In Internet Information Services (IIS) Manager, in the Connections pane, expand the computer name, expand Sites, and then click Default Web Site.

       3.      In the Actions pane, under Edit Site, click Bindings.

4.      In the Site Bindings dialog box, click the http entry, and then click Edit.
 
      5.      In the Edit Site Binding dialog box, in Port, type 8081, and then click OK.

7.      In the Site Bindings dialog box, click Close.

8.      In the Actions pane, under Manage Web Site, click Stop, and then click Start.

 

 

 

Thursday, 30 October 2014

Cognos: Auto Refresh Dashboard

Recently I developed a Cognos dashboard which gets refreshed after fixed time interval automatically. This can be achieved easly by using a simple script. Here are the steps:

-Insert a HTML item with below script

    <meta http-equiv="refresh" content="60">

-Select the query and set the "Use Local Cache" property to "No".
-Go to Cognos Connection
-Click report property and set the default action to "Run the Report" under Report tab.
-Run the report. You will see the report get refreshed after each 1 minute interval.

Wednesday, 29 October 2014

Cognos: Ranking using RowNumber() Function

Sometimes we may find hard to use rank function in our report to display Top-N rows. This can be easily solved using RowNumber function. Here are the steps

- Create a prompt with parameter name 'p_rank'
- Create a boolean variable

RowNumber()<=string2int32 (ParamValue('p_rank'))

- select the column on which you want to rank
- Click on Style Variable under Properties window and select the boolean variable
- Click Condition Explorer and select boolean variable value 'No'
- Select Box Type to None
- Run the report