Pages

Tuesday, 4 February 2014

Passing Parameter Through URL In Cognos 10 Report Studio:



What is URL?

URL stands for Uniform Resource Locator. A URL is a formatted text string used by Web browsers, email clients and other software to identify a network resource on the Internet. Network resources are files that can be plain Web pages, other text documents, graphics.

Example:

http://localhost:81/cognos/cgi-bin/cognos.cgi?b_action=xts.run&m=portal/cc.xts&gohome=

Passing Parameter Through URL:


Steps:

1)      Create a list report in cognos report studio.

2)      Create a parameterized filter on any data item like ‘Company Name’.

3)      Drag data item like ‘Company Name’,’ Country’,’ Contact Name’ into the list report.

4)      Run the report.

5)      Open cognos connection.

6)      Click on more… and from available Action click on ‘set properties’.



7)       Under general tag from the right side of the page click on View the search path, ID and URL.




8)      Copy the Default action URL: and paste it on URL.

9)     Like :

http://localhost:81/cognos/cgi-bin/cognos.cgi?b_action=cognosViewer&ui.action=run&ui.object=%2fcontent%2fpackage%5b%40name%3d%27Northwind%20Final%20PKG%27%5d%2freport%5b%40name%3d%27new%20URL%201_4%27%5d&ui.name=new%20URL%201_4&run.outputFormat=&run.prompt=true

10)   Add the prompt name and prompt value at the end of the URL like:

&p_prompt name=prompt value:

11)  Then URL will be like:

http://localhost:81/cognos/cgi-bin/cognos.cgi?b_action=cognosViewer&ui.action=run&ui.object=%2fcontent%2fpackage%5b%40name%3d%27Northwind%20Final%20PKG%27%5d%2freport%5b%40name%3d%27new%20URL%201_4%27%5d&ui.name=new%20URL%201_4&run.outputFormat=&run.prompt=true&p_Parameter1=Around the Horn

12)  This will give u the output only for this relevant Company Name.

13)  If u replace this &p_Parameter1=Around the Horn with this &p_Parameter1< >Around the Horn then it will show rest of the data Except “company name è Around the Horn ”

Hiding  the Prompt after value Selection:

1)      Same Steps From 1 TO 4:

2)      Click on value prompt and create a static choice like ‘hide’.

3)      Create a Boolean variable from conditional explorer having expression.

4)      Like: prompt   ‘contains’ ‘static choice’  è   ParamDisplayValue ('Parameter1') contains ‘hide’.

5)      Go to the report page and click on prompt select a Style variable from the properties ad select the variable that u create.

6)      Open the conditional explorer and select the value ‘yes ’

7)      Click the box type property from properties and set to ‘None’.

8)      Double click on green bar then you are outside the variable environment.  

9)      Save the report.

 
 Select the default prompt value from Cognos connection without applying any hard coated filter in report studio. 

1)      Open cognos connection.

2)      Click on more … and set properties.




3)      Click on ‘report ‘tag.


4)      Select the prompt value click on ‘Set…’

 


5)      And select value from the prompt.

6)      If u want to see prompt after running the report then check the box ‘prompt for values’.

7)      If u don’t want to see prompt after running the report then uncheck the box ‘prompt for values’.

8)      Click OK.

9)      Run the report.

10)  Then the URL will change

http://localhost:81/cognos/cgi-bin/cognos.cgi?b_action=cognosViewer&ui.action=run&ui.object=%2fcontent%2fpackage%5b%40name%3d%27Northwind%20Final%20PKG%27%5d%2freport%5b%40name%3d%27new%20URL%201_4%27%5d&ui.name=new%20URL%201_4&run.outputFormat=&run.prompt=true



  To 



http://localhost:81/cognos/cgi-bin/cognos.cgi?b_action=cognosViewer&ui.action=run&ui.object=%2fcontent%2fpackage%5b%40name%3d%27Northwind%20Final%20PKG%27%5d%2freport%5b%40name%3d%27new%20URL%201_4%27%5d&ui.name=new%20URL%201_4&run.outputFormat=&run.prompt=false



 For Further visit: http://www.segmentbi.com/

Tuesday, 28 January 2014

Remove Dotted Line From Value Prompt In IBM Cognos10 Report Studio.



Remove Dotted Line From Value Prompt.
In this paper we will discuss how we remove dotted line from value prompt. Cognos report studio support many built-in functionality that helps in reporting. But for some functionality we can use code of HTML (Hyper Text Markup Language) and JS (Java Script). That supports the cognos very well.

Steps :

·         Create a list report.

·         Select the value prompt from tool box.

·         Drag it on to the work area.

·         Write the name of prompt click next.

·         Select package item from available items.

·         Select the operator that you want to use like =,>, <, in, not in etc.

·         Choose the value that you want to display from available package items.

·         Click finish.

·         Drag HTML Item from tool box.







·         Double click on it and write the code using java script and HTML.

·         Code will be :

/* 
<script language="javascript">
// for removing elements in the prompt according to their indexes (position)
var list=document.getElementsByTagName("SELECT")[0];
list.remove(1);
list.remove(0);
list.removeAttribute("hasLabel");
list.options[0].selected = true;
canSubmitPrompt();
</script>          
*/
·         Remove ‘/*’ from the beginning and end of the code.
·         If you want to remove the element that is at index [0] then add  list.remove(0);
·         At position [0] there will be a name of column.
·         For removing the element from   position 2 add list.remove (2); etc.

·         list.remove(1); // for removing dotted line because it is at position 1.

·         list.remove(0); // for removing column name because it is at position 0.

·         Run the report.


   
For Further visit: http://www.segmentbi.com/

           

Monday, 27 January 2014

Content Manager And Its Infrastructure In IBM Cognos 10



What is Content Manager?

The IBM Cognos service that uses the content store is named Content Manager.

·         Content Manager is the IBM Cognos BI service that manages the storage of customer application data, including security, configuration data, models, metrics, report specifications, and report output.

·         Content Manager is needed to publish packages, retrieve or store report specifications, manage scheduling information, and manage the Cognos namespace.
·         Content Manager performs general functions, such as add, query, update, delete, move, and copy. It also performs content store management functions, such as export and import.
The information stored by Content Manager includes
  • reports
Reports contain specifications, properties, security settings, and outputs. This includes analyses created in Analysis Studio, queries created in Query Studio, and reports created in Report Studio.
  • report packages
Packages contain metadata, reports, and folders.
  • metric packages
Metric packages contain metadata, scorecards, and folders.
  • agents
Agents include the conditions, schedules, and tasks used to monitor events and deliver notifications. This includes the list of recently detected instances of an event.
  • server configuration
Server configuration contains directory information, the Cognos namespace Cognos Namespace, and information about contacts, distribution lists, data sources, and printers.
  • personal user information
Personal user information consists of My Folders and My Pages.
  • language information
Language information includes names, descriptions, and tool tips in different languages to support IBM Cognos BI multilingual capabilities.


Difference between Content Store and Content manager.

The content store is a relational database that contains data that IBM Cognos needs to operate,
 Such as
·         Report specifications, published models, and the packages that contain them.
·         Connection information for data sources.
·         Information about the external namespace, and the Cognos namespace itself.
·         Information about scheduling and bursting reports.
·        The relational database can be Cognos Content Database or another supported database.
·        Design models and log files are not stored in the content store.

  Content Manager uses a JDBC (Java Database Connectivity) API to access the content store and metric stores. IBM Cognos comes with the JDBC drivers for IBM Cognos Content Database and MS SQL Server. If you are using Oracle, IBM, or Sybase databases, ensures you obtain the appropriate JDBC drivers.
Report results in other formats, such as HTML, XML, and CSV (comma separated values), are stored in compressed form and are uncompressed by Content Manager before they are sent to a user.

Infrastructure of Content Manager.


                                            
Authentication Flow.
·      User makes request to access IBM Cognos Connection
·      Gateway accepts request and sends it to the Dispatcher
·      Dispatcher detects no Passport and sends request to Content Manager
·      Content Manager sends request to Cognos Access Manager
·      CAM returns fault with required information

o   System recoverable – Single Sign On (step 9)
o   User recoverable – Basic authentication

·      Content Manager returns request and fault to Dispatcher
·      The Dispatcher sends the request to the Presentation Service
·      The Presentation Service generates the login page and returns the page through the Dispatcher and Gateway to the user
·      The User enters their credentials, or it is pulled from the environment for Single Sign On
·      The Dispatcher sends the request to Content Manager
·      Content Manager sends the request to CAM
·      If the details are valid, CAM issues a passport and sends request to Content Manager.


Content Manager Cache Service:

·         Each Dispatcher maintains a local cache for objects retrieved from Content Manager Service.
·         Used to decrease load on the active Content Manager and improve speed Objects subject to caching.
i)        Report, Report Cache, Package, Package Configuration, model, model Views, Data source Signon, account, session.

For Further visit: http://www.segmentbi.com/