Groups | Blog | Home
all groups > sql server reporting services > may 2007 >

sql server reporting services : Skipping the display of dataset rows in a report table


mjlinhbg
5/30/2007 11:56:01 AM
I have a stored procedure which returns three rows from the database into a
dataset (two credits, one debit). My report has two tables (on a list); one
for credits, one for debits. The list is associated with the dataset.

The expressions for the textboxes in the tables contain an "if" statement
[iif(Fields!CRAmount.Value > 0, Fields!CRAmount.Value, Nothing) ...intended
to display only the credits OR debits]. While this works, the report also
reserves space for the rows of the dataset which do not meet the criteria in
the if statement. In other words, the "Nothing" display appears to take space
in the report.

Is there another way around this?

Appreciate any help I can get.
Carl Henthorn
5/30/2007 12:10:01 PM
I had a simular problem just the other day.
Try adding a "rowid" field to your sproc output that is an identity field.
Then in your report layout, you can put in three detail rows under your
header. On the visiblity property for the entire row, put in a formula
something like :
=Iif(rowid=1, false, true) for the first row, =Iif(rowid=2, False, True) for
the second row, etc.

[quoted text, click to view]
AddThis Social Bookmark Button