Cognos Percentage calculation by total

percentage([Counts])
percentage(count (distinct [DataItem]))

Create a calculation by above syntax. Drag that column to cross-tab. You should be getting percentages of summary data.

Topics: Cognos Cross Tab & percent calculation in Total
cognos cross tab how to add percentage

https://it.toolbox.com/question/crosstab-percent-calculation-in-total-071706

Cognos how to hide pages/fields based on output format

 

create a render variable with ‘Expression Definition:’ as

ReportOutput () in ( ‘spreadsheetML’) –this would give output only for excel output report
ReportOutput () in ( ‘PDF’) — this would give specified output only for pdf output report.
ReportOutput () not in ( ‘PDF’) — This will hide specified output for pdf output report

Values that you could pass are available at below link.
https://www.ibm.com/support/knowledgecenter/SSEP7J_10.2.1/com.ibm.swg.ba.cognos.ug_md.10.2.1.doc/c_crx_reportoutput.html

 

Save cognos report to file system / Bursting Cognos Reports to File System

Save cognos report output to a server/network drive.
Bursting Cognos Reports to File System

To achieve bursting first we should make sure all the below steps are completed and tested.

Steps:
part A: Configure Cognos Configuration.
1. Create a shared folder. Make sure that cognos servers are having access to this folder by checking properties, security of that folder
2. Go to Cognos Configuration –> actions–> General –> Archive file location –> type : file://\\servername\directory or file:///
3. Click test to make sure your syntax and access to that folder are accessible.
4. Go to “Data Access”–> Content Manager–> “Save report output to a file system” –> Change the value to “True”.
5. Restart the cognos service.
6. Save cognos configuration and restart the service.
7. Make above changes to all the content managers.

Part B: Creating File system at Cognos Connection
1. In Cognos administration, go to Configuration –> dispatcher and services
2. top right hand side click on “Define File system Location”
Define file system location
3. New — > provide name, File system location (this would be sub folder under file system location)
4. click Finish
You can create more file system locations to save reports in different folders in same main folder. This way you will have multiple folders at your file system location.

Part C: Saving the report to file system location.
1. at cognos connection go to required report — > “run with options” –> Advanced Options –> Run in the background –> You will see a new option on your right near delivery- “Save to the file system”. check this box and click on ” Edit the file system options”.
2. select/provide required location, Conflict Resolution, Name.
3. Click OK and then Run.
4. you would see new report in the new folder you mentioned

after above steps are completed and tested as required we can re-do Part-C by checking Bursting Option which would help the report to Burst to required folder.

Sources:
http://www-01.ibm.com/support/docview.wss?uid=swg21342666
http://www-01.ibm.com/support/docview.wss?uid=swg21381810

Cognos analytics- how to run a report using URL

Check below link for details.
http://www-01.ibm.com/support/docview.wss?uid=swg21983556

By using above mentioned steps your final url will look like

http://servername:9300/bi/v1/disp?b_action=cognosViewer&run.outputFormat=HTML&run.prompt=true&ui.object=storeID (%22insert_StoreID_here%22)&ui.action=run&cv.header=false&cv.toolbar=false
9300[servername/ibmcognos/cgi-bin/cognosisapi.dll?b_action=cognosViewer&run.outputFormat=HTML&run.prompt=true&ui.object=storeID(%22insert_StoreID_here%22)&ui.action=run&cv.header=false&cv.toolbar=false

Cognos how to customize search and select prompt

Cognos How to resize Select and Search prompts
Cognos How to change the default prompt option of search and select

use html2 for resize
use html3 for  default option to contains

add 3 html items. 1 item before prompt and 2 items after prompt.

Prompt name say” ParName”

cognos customize search and select prompt

cognos customize search and select prompt html code

source:
http://www-01.ibm.com/support/docview.wss?uid=swg21341018

Quickie: Changing default option in a Select and Search Prompt


https://www-01.ibm.com/support/docview.wss?uid=swg21902305
https://www.cognoise.com/index.php?topic=26076.0

 

 

Pass data item/query item into Hyperlink. How to get Google maps links at Cognos.

For this example I am using google maps.
Google maps URL –
https://www.google.com/maps/search/?api=1&query=58.698017,-152.522067

Create 2 query items with latitude and longitude. Say [Query Item Latitude], [Query Item Longitude]
create a new data item say – [Query Item_google maps url] with
https://www.google.com/maps/search/?api=1&query= ‘ ||cast([Query Item Latitude] as varchar(10))||’,’|| cast([Query Item Longitude] as varchar(10))

at report studio drag hyperlink to your list report.
Select Hyperlink and change properties as follows
Source type – Data Item value
Data Item Value – [Query Item_google maps url]
Googlemaps

Run the report. You should be able to get to google maps from the hyperlink.

Another google map URL you can play with –
https://maps.google.com/?hl=en&ll={LATITUDE},{LONGITUDE}&t=m&z=19&vpsrc=6&layer=c&cbll={LATITUDE},{LONGITUDE}&cbp=12,15.61,,0,0

Here is the URL API guide from google: https://developers.google.com/maps/documentation/urls/guide