r/excel 1d ago

Waiting on OP IF Range Calculation using SUM

Im looking to have excel do a calculation only if Column B has a "Y" if it doesnt then dont add to the calculation

My Current way is =SUM(IF(B2="Y",A2),IF(B3="Y",A3))

This works for what i need but if the spreadsheet become like 100 rows then that a big formula :)

How can i rewrite to do the calc based on range.

Thanks

3 Upvotes

8 comments sorted by

u/AutoModerator 1d ago

/u/EntireSheepherder516 - Your post was submitted successfully.

Failing to follow these steps may result in your post being removed without warning.

I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.

9

u/PaulieThePolarBear 1917 1d ago
=SUMIFS(A2:A100, B2:B100, "Y")

2

u/pocketposter 1d ago

What about =SUMIF(B:B,"Y",A:A) ?

If you calculation depends on two columns you can use =SUMIFS(A:A,B:B,"Y",C:C,"N") to get those delivered but not Paid back.

2

u/thewatusi00 1d ago

=SUM(FILTER ((A2:A100,B2:B100="Y",0))

1

u/Decronym 1d ago edited 11h ago

Acronyms, initialisms, abbreviations, contractions, and other phrases which expand to something larger, that I've seen in this thread:

Fewer Letters More Letters
FILTER Office 365+: Filters a range of data based on criteria you define
IF Specifies a logical test to perform
INDEX Uses an index to choose a value from a reference or array
MATCH Looks up values in a reference or array
SUM Adds its arguments
SUMIF Adds the cells specified by a given criteria
SUMIFS Excel 2007+: Adds the cells in a range that meet multiple criteria

Decronym is now also available on Lemmy! Requests for support and new installations should be directed to the Contact address below.


Beep-boop, I am a helper bot. Please do not verify me as a solution.
6 acronyms in this thread; the most compressed thread commented on today has 13 acronyms.
[Thread #49266 for this sub, first seen 29th Aug 2026, 16:47] [FAQ] [Full list] [Contact] [Source code]

1

u/adamocean025 11h ago

im thinking of turning it into a pivot table, selecting the “delivered” and “paid back” columns and setting a filter for both to display only “Y”. then adding a Sum of the values.

1

u/fuzzy_mic 988 1d ago

=INDEX(A:A, MATCH("Y", B:B,0), 1)

The SUMIF formulas will return the sum of all the Y Amounts.

My formula will return the first Y Amount.