Solved

How to hide a  null column in Cognos 8

Posted on 2011-09-06
10
2,737 Views
Last Modified: 2012-05-12
Hi,

I want to hide a column which is null in one of my cognos report.

The rows of that column have data  but the column is empty and I need to hide it. It is a cross tab report.

                      report Design
0
Comment
Question by:new_perl_user
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 5
10 Comments
 
LVL 8

Expert Comment

by:SNeupane
ID: 36490819
What happens when you select the column and go to properties, click on 'Box Type' and set it to 'None'?
0
 

Author Comment

by:new_perl_user
ID: 36490865
when the data of that column is null then I need to hide, but sometimes it has data as shown below.

 REPORT
0
 
LVL 8

Expert Comment

by:SNeupane
ID: 36490979
You can't hide that column if some other rows have value in the same column.
If you hide the null cells, then the total value will move into that place and report  data will look messed up as some total will be in the 2nd for null and others will be in the 3rd.
With some conditional formatting, you may be able to hide the borders for the null cells but hiding doesn't work if there are some values.
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:new_perl_user
ID: 36491032
so is there any other workaround  for this issue to avoid the null columns. If so can you please let me know.

Thanks,
0
 
LVL 8

Expert Comment

by:SNeupane
ID: 36491103
Hiding doesn't make sense in this situation as you'll always have the space from the rows that have values.
You can only conditionally format using a variable to remove the border when value is null so it looks like one big cell instead of two cells.
0
 

Author Comment

by:new_perl_user
ID: 36491134
oh ok. But these null values are coming when I wrote a condition to get only the states for 'US'.

Below condition is for 'US' only but I have no clue why it is pulling out even 'Canada' values as null data into the report.

case
when(substring([id],3,1)='U')
then ('US-' + upper("GET_INFO_PKG.GET_NAME" ([State Code])) + '   '  + 'TOTAL')  end

Is my condition wrong ..
0
 
LVL 8

Expert Comment

by:SNeupane
ID: 36491252
If you are getting correct data from the condition, it's good.
If it gives you extra null rows, you can deal that with a conditional variable.
Create a variable with a condition that checks the column for null.
Use that variable to hide the entire row including all cells on the null value.
Refer to Report Studio user guide on how to use the conditional variable for conditional formatting.
Then, the null rows will be gone.
0
 

Author Comment

by:new_perl_user
ID: 36491601
Hi,
Followed the below steps but it is not working..

1)  Created a Boolean variable with expression as :  if (state) is null
2)  navigated to the report selected the state column  and went to properties > style Variable.
3)  In style Variable selected the Boolean variable created.
4) then in conditional explorer selected the 'Yes' button and it turned green

But when I run the report still the same issue.

Am I missing something plss let me know.  Is my condition wrong to check for null values.
0
 
LVL 8

Accepted Solution

by:
SNeupane earned 500 total points
ID: 36491643
When it turned green, select all rows and all cells of crosstab except the column level on top and then set box type to 'None'.
0
 

Author Comment

by:new_perl_user
ID: 36492084
Thank you so much it worked.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Problem Statement In an SAP BI BO Integration project when a BO universe is built on a BEx query, there can be an issue of unit & formatted value objects not getting generated in a BO universe for some key figures. This results in an issue whereb…
Today, still in the boom of Apple, PC's and products, nearly 50% of the computer users use Windows as graphical operating systems. If you are among those users who love windows, but are grappling to keep the system's hard drive optimized, then you s…
If you're a developer or IT admin, you’re probably tasked with managing multiple websites, servers, applications, and levels of security on a daily basis. While this can be extremely time consuming, it can also be frustrating when systems aren't wor…
There's a multitude of different network monitoring solutions out there, and you're probably wondering what makes NetCrunch so special. It's completely agentless, but does let you create an agent, if you desire. It offers powerful scalability …

724 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question