Hide empty rows in tablix ... ??
Hi
I have created a simple dataset. A very simple quick and dirty solution like this:
Select Month AS 'Month', NULL AS 'Dept', NULL AS 'Rev' (...and so on...) into #Temp1 From Periods
Union
Select Month AS 'Month', Department AS 'Dept', Revenue AS 'Rev' (...and so on...) * From Statitics
Select * From #Temp1
I have a couple of where clauses such as company, month and so on ... but ... as I union these two selections ... I will always get an empty row
Januari NULL NULL NULL NULL (...and so on...)
and this row will turn up on the top of my matrix.
My question is ... how do I hide this row?
The thing is that I want to show the Revenue for a specific Department for the entire year ... but sometimes I don't have a reveneu for a specific month ... but I still want that month shown. I don't want it to jump over a month jsut because it ain't got
a revenue inserted in the db.jea
November 5th, 2010 8:29am
Your question is a bit confusing do you want to show all months in the year regardless of whether they have data in table Statistics, or do you want them to disappear if they have no data?My Blog "Karl Beran's BI Mumble"
Free Windows Admin Tool Kit Click here and download it now
November 8th, 2010 1:01pm
why dont you try expresion while doing grouping and on label as well.
see if it works
=IIF(Isnothing(Fields!yourfield.Value),nothing,Fields!yourfield.Value)Gaurav Gupta http://sqlservermsbiblog.blogspot.com/
November 8th, 2010 1:14pm
Hi jea,
Actually, report control could only display the records, which are in the dataset. From your information I get that
there is no record in some special month, so here you should create another table to contain the full month name you want to display, then left join the data table. The result will still return Null value even if there is no record in some special month. In
this condition, you could utilize the expression to display zero or NoData information.
Best regards,
Challen Fu
Free Windows Admin Tool Kit Click here and download it now
November 9th, 2010 2:49am
You can use the filter feature available with ssrs tablix.
Select the detail group or the group you created inside tablix.
Right click on it and go to filter tab. Provide the expression or fieldname with which you want to filter the data, specify the criteria ( > , < , = etc) and the value ( eg 0)
Hope it helps.
November 9th, 2010 9:40am
you can also try including the check for "" in the logic above, something like,
=IIF(Isnothing(Fields!yourfield.Value) OR Fields!yourField.value = "",nothing,Fields!yourfield.Value)
HTH,
Suman
Free Windows Admin Tool Kit Click here and download it now
November 9th, 2010 10:09am
Thanks guys. Sorry for the delayed answer ... been aways these couple of days.
We change the grouping and didn't have a need for hiding rows for now. But you gave me ideas for other reports. Thanks a lot!!jea
November 12th, 2010 5:23am