Vikram SE
Vikram SE

Reputation: 297

Filter expression at runtime in SSRS 2008 R2

I have applied a filter expression for group level like this in SSRS 2008 R2:

=((Fields!Cases_Shipped.Value >= Parameters!CasesShipped.Value 
    And Fields!Stocked.Value In('','Yes','No'))
Or
    (Fields!Cases_Shipped.Value < Parameters!CasesShipped.Value 
    And Fields!Stocked.Value In('Yes',''))) 

Here Cases_Shipped is the name of the column in which the filter has to be applied when we select a value of cases shipped value from a drop down list.

Stocked is another column.

Criteria is working ok at sql server but in this manner in SSRS it shows error.

The FilterExpression expression for the tablix ‘table1’ contains an error: [BC30198] ')' expected.

Help Please!!

Upvotes: 1

Views: 6879

Answers (2)

Shaikh Farooque
Shaikh Farooque

Reputation: 2640

What you need in return that is missing from the above expression.

Kindly add the result what you want from this expression.

Upvotes: 0

Chris Latta
Chris Latta

Reputation: 20560

The error message tells you the problem - you haven't closed your brackets. You are missing the final ) to close the first open bracket.

=(  (Fields!Cases_Shipped.Value >= Parameters!CasesShipped.Value 
    And Fields!Stocked.Value In('','Yes','No'))
Or
    (Fields!Cases_Shipped.Value < Parameters!CasesShipped.Value 
    And Fields!Stocked.Value In('Yes','')) )

Upvotes: 1

Related Questions