"Where" Condition in RDLC Vb.net

Viewed 38

I have a table like :

ColumnA ColumnB
8.75 J
5.05 T
6.1 T
8.5 J

I want to sum ColumnA data where ColumnB = J and show it in one of the RDLC textboxes.

What I should write in the Expression Field?

1 Answers

You can use the following expression.

=Sum(IIf(Fields!ColumnB.Value, 1) = "J", CDbl(Fields!ColumnA.Value), 0)

Use IIF( expr truepart,falsepart) to determine if the value is J, and Sum() to calculate the sum.

Related