Wednesday, March 21, 2012

Interesting conumdrum.. question about filters...

Got a dataset coming from a stored procedure.

There is a parameter I must put on the report that filters the dataset.

the choices are "exclude" and "only", based on that I have to filter my dataset like

if they select exclude then I have to filter where "debitType <> 'Intercompany'"

if they select on;y then I have to filter where "debitType = 'Intercompany'"

Is this at all possible in the filter part?

It is easy as pie in Crystal record selector.

Hello,

Try this as your filter:

Expression: =cBool((Fields!debitType.Value <> "Intercompany" AND Parameters!Param1.Value = "Exclude") OR (Fields!debitType.Value = "Intercompany" AND Parameters!Param1.Value = "Only"))

Operator: =

Value: =cBool(True)

Hope this helps.

Jarret

|||

oh, that's good. didn't knwo you could use epxressions like that in the left side of the filter table.

Thanks alot.

No comments:

Post a Comment