Overriding data formatting using patterns
In Cognos Report Studio, we can define the formatting of data items that we have seen in many recipes. However, sometimes the formatting defined in the report does not take effect. In this recipe, we will consider one such scenario.
Getting ready
Create a simple crosstab report with all Product line on rows and Month key on columns from GO Data Warehouse (Query)/Sales. Choose Revenue and Planned revenue as measures.
How to do it...
In this recipe we will see how to use patterns in the data format. To do this, perform the following steps:
Firstly, let's run the report to check how the measured data are formatted.
You will notice that some numbers have two decimal places while some have one decimal place.
Now, go back to Cognos Report Studio. Select the measures and open the data format again.
This can be done in the data format using the Number of Decimal Places option, but this time we will check another functionality. Go to Pattern and define it as
#,#...