Cognos Visualization error


The web request failed.


404 – Not Found
URL: http://cognosserver/ibmcognos/bi/common/palettes.json


On your webserver pallettes.json needs to be copied from install location analytics\webcontent\bi\common  to the analytics\webcontent\bi\common folder

Key words for search:


404 – Not Found – palettes.json

Cognos Percentage calculation by total

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

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:
items: [xlsxData, CSV, spreadsheetML, HTML, layoutDataXML, PDF, XML, XLWA, MHT, rawXML, XHTML, singleXLS, HTMLFragment]
case sensitive: true


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.

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.


Cognos analytics- how to run a report using URL

Check below link for details.

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

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


Quickie: Changing default option in a Select and Search Prompt



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 –,-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 ‘ ||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]

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

Another google map URL you can play with –{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:

cognos dates

_first_of_month(_add_months(current_date,-3)) — 1st of last 3rd month i.e. for march 10th 2018 you will get output as Dec 1st 2017

— end of last month
-Last day of the previous month can be determined by using the following expression:

-First day of the previous month can be determined by using the following expression:

–current date

–current date-1 or yesterday date
_add_days ( current_date, -1)

— current year last 7th day
_add_days ( current_date, -7)

–current year
extract (year, current_date)

— current year First Day of Year
_add_days(Current_date , (_day_of_year(Current_date)*-1)+1 )

–CY Total Days till today
_day_of_year (current_date)

–CY Total Days till last 7th day
_day_of_year (_add_days(current_date,-7))

— CY First Day of Current Month
_first_of_month ( current_date)