Using CR11 and sql, I have a table with a 1-many relationship, and I'm trying to do a calculation on 2 fields. My data looks like this:
Claim Num Error ID Resolution ID Formula
6093960 22 ?
6093960 24 5 2.00
6093960 25 ?
6093960 41 ?
etc.
My formula is trying to account for both records with an Error ID of 22 or 24, and where the resolution ID is either 3, 5, or NULL.
So my formula is:
if {table.ErrorId} in [22,24] and
({table.ResolutionId} in [3,5] OR
IsNull({table.ResolutionId})
then
total := total + (1 * 0.02) *100
the last part is to add to the running total and make it a percent. But both the 1st and 2nd records should have a formula result of 2, but only the 2nd record with the resolutionID of 5 is having the formula applied.
I'm hoping this is something silly in my formula I'm missing? Any help is greatly appreciated, thanks!
Claim Num Error ID Resolution ID Formula
6093960 22 ?
6093960 24 5 2.00
6093960 25 ?
6093960 41 ?
etc.
My formula is trying to account for both records with an Error ID of 22 or 24, and where the resolution ID is either 3, 5, or NULL.
So my formula is:
if {table.ErrorId} in [22,24] and
({table.ResolutionId} in [3,5] OR
IsNull({table.ResolutionId})
then
total := total + (1 * 0.02) *100
the last part is to add to the running total and make it a percent. But both the 1st and 2nd records should have a formula result of 2, but only the 2nd record with the resolutionID of 5 is having the formula applied.
I'm hoping this is something silly in my formula I'm missing? Any help is greatly appreciated, thanks!