1
votes

My CSV contains the below data.

enter image description here

I am using a calculated field that is returning 40.

IF CONTAINS([Description],'Veg')
THEN [Amount]
END

But I want to total the sum amount of the bill numbers where any bill number matches these criteria - Description contains Veg.

here, bill number 2 contains veg in 1 row (10), so I want to get the total amount of that full bill number (20).

My expected output is 50.

enter image description here

1

1 Answers

1
votes

Not that difficult. Proceed like this-

create your desired amount field by this calculation-

IF { FIXED [Bill]: MAX(INT(CONTAINS([Description], 'veg')))}>0
THEN [Amount] ELSE 0 END

Screenshot

enter image description here

enter image description here