Solved

SSRS - Non-existent row/column group appearing

Posted on 2014-10-22
7
1,635 Views
Last Modified: 2014-10-23
I have a sample dataset attached in Excel, and as you can see, the last field is called UtilityOrder and is returning 1, 2, or 3 only. I have a tablix containing a few expressions and a gauge, and as you can see here, I've set up RowGroup and ColumnGroup on the tablix:

Design View
Group Expressions are:
RowGroup = Floor((Fields!UtilityOrder.Value-1) / 2)
ColumnGroup =(Fields!UtilityOrder.Value-1) Mod 2

In this example, the intention is that tablix panels go across the row, and once 2 have been placed, a new row is started. The problem is that I'm getting a phantom 4th panel. I've added UtilityOrder to the third expression to illustrate:

Gauge screen output
Why is the 4th panel appearing when UtilityOrder=4 doesn't exist?

Thanks,
Jeff
0
Comment
Question by:jdallen75
  • 4
  • 3
7 Comments
 
LVL 22

Accepted Solution

by:
Nico Bontenbal earned 500 total points
ID: 40398779
The cell in the matrix is there because there is a row an a column for it. There just no value in the cell. With normal text fields these would come up empty most of the time, so you won't notice. But now there is a gauge in the cell so you get a gauge without a value. The solution is to use the Hidden propery of the gauge to hide it when there is no value. You can do this by setting the hidden propery to:
=Fields!UtilityOrder.Value is nothing

Open in new window

You can do this in the properties list directy or in the Gauge Panel Properties window in the Visibility section in the 'Show or hide based on an expression' field.
0
 

Author Comment

by:jdallen75
ID: 40399435
Nicobo,

Thanks for the reply. That *almost* worked. I had to apply that visibility expression to each object (gauge and 2 text objects) and it worked for them. But for some reason, in the header, it thinks UtilityOrder is 2?? (It's almost like a leftover from the object above it). I've also applied the visibility on the tablix object 2, but the header is causing it to remain:

Almost hidden!
Any thoughts?
0
 
LVL 22

Expert Comment

by:Nico Bontenbal
ID: 40399775
Strange indeed. It almost seems like a bug. There is no record meeting the columns and row grouping so the fields should be empty. I was able to solve it by using this formula for the hidden property:
=sum(Fields!UtilityOrder.Value) is nothing

Open in new window


And now I think about it looks a lot more like bug. Because how can sum(Fields!UtilityOrder.Value) be nothing when Fields!UtilityOrder.Value has a value.
0
Migrating Your Company's PCs

To keep pace with competitors, businesses must keep employees productive, and that means providing them with the latest technology. This document provides the tips and tricks you need to help you migrate an outdated PC fleet to new desktops, laptops, and tablets.

 

Author Comment

by:jdallen75
ID: 40399964
I'm pretty sure it's a bug, but a colleague of mine managed to find a work-around:

1. Remove the grouping on the existing tablix (and name it InnerTablix)
2. Apply the visibility expression to this InnerTablix
3. Drop another matrix on the page, and call it OuterTablix
4. Bind the same dataset to this OuterTablix
5. Configure the row and column groups as before
6. Delete extra rows and columns

So far, it has worked for 2 examples.
Thanks again, Nicobo
Jeff
0
 

Author Closing Comment

by:jdallen75
ID: 40399967
Your suggestion got me on the right track.. even if there's an underlying bug.
0
 

Author Comment

by:jdallen75
ID: 40399970
Sorry, I missed the "Sum" part in your previous comment. I'll try that again on my next example to fix. Thanks.
0
 
LVL 22

Expert Comment

by:Nico Bontenbal
ID: 40400176
Another way to fix it might be using one cell only and place a rectangle in that cell. Inside the rectangle you can place multiple controls (gauges and textboxes). Then you can set the visibility of the rectangle.
0

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Question has a verified solution.

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

In this article I will describe the Copy Database Wizard method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
This article shows gives you an overview on SQL Server 2016 row level security. You will also get to know the usages of row-level-security and how it works
Familiarize people with the process of retrieving data from SQL Server using an Access pass-thru query. Microsoft Access is a very powerful client/server development tool. One of the ways that you can retrieve data from a SQL Server is by using a pa…
Using examples as well as descriptions, and references to Books Online, show the different Recovery Models available in SQL Server and explain, as well as show how full, differential and transaction log backups are performed

791 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