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/
No comments:
Post a Comment