Previous/Next Functions
I am running SSRS 2008 R2. Is there a way to do a previous or next function in ssrs similar to what crystal has.
What I am trying to do is basically supress the whole row if one field in it is the same as the previous row.
E.g IIF((Fields!customerid.Value) <> Previous(Fields!customerid.Value),1,0) in the expression for being visible.
Anything like this in SSRS?DBA
November 4th, 2010 6:11pm
Check in miscellaneous category, you will get a Previous
function.
To know more about it
http://msdn.microsoft.com/en-us/library/ms156372(SQL.90).aspx
Gaurav Gupta http://sqlservermsbiblog.blogspot.com/
Free Windows Admin Tool Kit Click here and download it now
November 4th, 2010 6:14pm
How would I code that I am confused. I tried that in the filtering, but it said The properties for the currently select item are not valid. Isn't there a way in the grouping that I could just do like I showed?DBA
November 4th, 2010 6:28pm
can you please post expression you tried and where you tried??
Gaurav Gupta http://sqlservermsbiblog.blogspot.com/
Free Windows Admin Tool Kit Click here and download it now
November 4th, 2010 6:36pm
=iif(Previous(Fields!customerid.Value)<> Fields!customerid.Value, 1,0)
And I put it in under the Visibility Expression for the group
DBA
November 4th, 2010 6:42pm
The visibility expression is actually the Hidden expression in reality:
=iif(Previous(Fields!customerid.Value)<> Fields!customerid.Value, FALSE,TRUE)Rgds Geoff
Free Windows Admin Tool Kit Click here and download it now
November 5th, 2010 12:30am
That was exactly what I was looking forDBA
November 8th, 2010 1:42pm
I am having an issue with this expression. It used to work in SSRS 2005.
=STRDUP(LEVEL()*10," ") +
IIF(Fields!RecordType.Value = "Product",
IIF(Fields!RecordType.Value = PREVIOUS(Fields!RecordType.Value),"","Production"),
LEFT(Fields!ChildNbr.Value,9)) +
IIF(Fields!Cycle.Value<>0, IIF(Fields!RecordType.Value="Offering", "*", ""), "")
I tried importing this RDL into SSRS 2008 R2 via BIDS Wizard but got
The Value expression for the text box ‘textbox2’ has a scope parameter that is not valid for an aggregate function. The scope parameter must be set to a string constant that is equal to either the name of a containing group, the name of a containing
data region, or the name of a dataset. (rsInvalidAggregateScope)
I can't seem to find what's wrong with it. I actually removed the last + clause but doesn't seem to help either. Thoughts?
Free Windows Admin Tool Kit Click here and download it now
March 7th, 2011 3:22pm