SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Remove/Suppress line/row if blank


Remove/Suppress line/row if blank

Author
Message
tshadab
tshadab
Grasshopper
Grasshopper (17 reputation)Grasshopper (17 reputation)Grasshopper (17 reputation)Grasshopper (17 reputation)Grasshopper (17 reputation)Grasshopper (17 reputation)Grasshopper (17 reputation)Grasshopper (17 reputation)

Group: General Forum Members
Points: 17 Visits: 2
In VFP there is a value called 'remove line if blank' which eliminates blank space. How it could be done in SQL Reporting Services?

OR in Crystal report there also an option of row property "suppress if blank"

Any one have idea how it can be achieved in SQL Reporting?

Thanks
nigel.c.west
nigel.c.west
Right there with Babe
Right there with Babe (732 reputation)Right there with Babe (732 reputation)Right there with Babe (732 reputation)Right there with Babe (732 reputation)Right there with Babe (732 reputation)Right there with Babe (732 reputation)Right there with Babe (732 reputation)Right there with Babe (732 reputation)

Group: General Forum Members
Points: 732 Visits: 337
In Reporting Services almost every object (including rows in tables) has a property called Visible, this property can be set using an expression. Let's assume you have a column called SalesRegion and you want to blank the details line if this field is blank:

First, select the details line on the left side and then go to the properties area, click on the Visible property to open it up then click on the drop down next to Hidden and select expression.

In the expression you would put something like this:

=IIF(Fields!SalesRegion.Value = "",TRUE,FALSE)

Basically what this means is if the sales region is blank then set the attribute Visible/Hidden to TRUE (i.e. hide the object) otherwise set it to FALSE (display the object).

Good luck,
Nigel.

Nigel West
UK
yolip-456327
yolip-456327
Grasshopper
Grasshopper (18 reputation)Grasshopper (18 reputation)Grasshopper (18 reputation)Grasshopper (18 reputation)Grasshopper (18 reputation)Grasshopper (18 reputation)Grasshopper (18 reputation)Grasshopper (18 reputation)

Group: General Forum Members
Points: 18 Visits: 13
I believed we are looking for a solution to hide a line object in crystal report not the field
Margaret Norkett
Margaret Norkett
Valued Member
Valued Member (55 reputation)Valued Member (55 reputation)Valued Member (55 reputation)Valued Member (55 reputation)Valued Member (55 reputation)Valued Member (55 reputation)Valued Member (55 reputation)Valued Member (55 reputation)

Group: General Forum Members
Points: 55 Visits: 26
I've done this, but it still gives me a blank line.

Any other suggestions?

Thanks,

Margaret


Thanks and have a NICE day!,

Margaret

jereme.guenther@gmail.com
jereme.guenther@gmail.com
SSCommitted
SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)

Group: General Forum Members
Points: 1501 Visits: 194
I too am having a similar problem.

I am trying to suppress certain columns in a matrix. I have set the visible property on them to False and they are rendering as blank columns.

I am trying to add a custom totals column to each group. so I have created a parent group which holds two child groups, the second child group is a single column of custom totals. I have collapsed and hidden the first child group so everything is displaying correctly, except that the first child column still exists as a blank column.

I know I can accomplish this in RS2008, but I don't have that option, I am stuck in RS2005. I'll try and post here if I ever find a solution, but it seems unlikely at this point.
sgmunson
sgmunson
SSCoach
SSCoach (17K reputation)SSCoach (17K reputation)SSCoach (17K reputation)SSCoach (17K reputation)SSCoach (17K reputation)SSCoach (17K reputation)SSCoach (17K reputation)SSCoach (17K reputation)

Group: General Forum Members
Points: 17567 Visits: 4638
Actually, the property is the "Hidden" property, and it's within a property group known as Visibility. When set to False, the object IS visible, and when set to True, the object disappears. In a table, you would need the entire row's visibility to change, which is separately controllable from the individual text boxes within. You have to make the entire row hidden and not just the individual text boxes within it. Each row has a separate "Hidden" property.

Hopefully, that helps clarify where to set the expression, and clears up what to set it to to get invisibility.

This DOES apply to RS 2005, by the way.

Steve
(aka smunson)
SmileSmileSmile

Steve
‌(aka sgmunson)
Smile Smile Smile
Health & Nutrition
jereme.guenther@gmail.com
jereme.guenther@gmail.com
SSCommitted
SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)

Group: General Forum Members
Points: 1501 Visits: 194
My visibility issue is with a matrix column (actually a collapsed group column), not a table row. Table rows are much simpler to make the visibility thing work on.

While I still haven't solved the visibility issue, I did find an alternate method of solving the source problem. My original issue was needing a custom totals column for my column grouping in a matrix table in RS2005.

It has been my experience that reporting services is extremely bad at handling large amounts of data, so I generally do as much aggregating in a stored procedure as possible before returning the result set to reporting services. This means that at my lowest level of grouping in a matrix reporting services isn't doing any aggregating, it is simply displaying the data.

Because of this I can wrap the lowest level in either First(), Last(), or Sum() and it will return the same value when fully expanded; however the functions play a critical role when the group is collapsed. If I have created a custom total column and ordered it last in each of my column groupings then I can wrap the value in the Last() function and when the group is collapsed it will only display the last column of values rather than auto summing them for me.
sgmunson
sgmunson
SSCoach
SSCoach (17K reputation)SSCoach (17K reputation)SSCoach (17K reputation)SSCoach (17K reputation)SSCoach (17K reputation)SSCoach (17K reputation)SSCoach (17K reputation)SSCoach (17K reputation)

Group: General Forum Members
Points: 17567 Visits: 4638
Jereme,

Most of my post was intended at clarifying the details, as many questions were asked that suggested there was confusion. Even one of your posts talks about having the visibility property as False to hide the column, and, at least in RS 2005 anyway, that would need to be set to True to hide any given object. As you also referred to it as "visibility", clarifying that it's actually the "hidden" property might help folks understand why True means don't display it and False means display it. If you set it to False, that could have been your problem.

Of course, in your situation, avoiding the need in the first place is a much better solution.

Steve
(aka smunson)
SmileSmileSmile

Steve
‌(aka sgmunson)
Smile Smile Smile
Health & Nutrition
jereme.guenther@gmail.com
jereme.guenther@gmail.com
SSCommitted
SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)SSCommitted (1.5K reputation)

Group: General Forum Members
Points: 1501 Visits: 194
smunson (8/21/2008)
Jereme,

Most of my post was intended at clarifying the details, as many questions were asked that suggested there was confusion. Even one of your posts talks about having the visibility property as False to hide the column, and, at least in RS 2005 anyway, that would need to be set to True to hide any given object. As you also referred to it as "visibility", clarifying that it's actually the "hidden" property might help folks understand why True means don't display it and False means display it. If you set it to False, that could have been your problem.

Of course, in your situation, avoiding the need in the first place is a much better solution.

Steve
(aka smunson)
SmileSmileSmile


Good point Steve. I was trying to refer to the concept rather than a specific attribute, probably should have been more specific.
pat_vrs
pat_vrs
SSC Rookie
SSC Rookie (25 reputation)SSC Rookie (25 reputation)SSC Rookie (25 reputation)SSC Rookie (25 reputation)SSC Rookie (25 reputation)SSC Rookie (25 reputation)SSC Rookie (25 reputation)SSC Rookie (25 reputation)

Group: General Forum Members
Points: 25 Visits: 10
tshadab (3/6/2008)
In VFP there is a value called 'remove line if blank' which eliminates blank space. How it could be done in SQL Reporting Services?

OR in Crystal report there also an option of row property "suppress if blank"

Any one have idea how it can be achieved in SQL Reporting?

Thanks



I think tshadab want to remove the blank line.. when an object is hidden in Reporting Services..

like a floating option:

textbox1
textbox2 (set to hidden)
textbox3

to get:
textbox1
textbox3

NOT
textbox1
<-- (blank line)
textbox3


(you can check my other post on microsoft's forums)
http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=2228455&SiteID=1
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search