Excel Sum Only 'Done' Rows: Ask AI for the SUMIF Formula
When this happens
You track tasks in Excel. Column B says 'Done' or 'In progress', and column C has the amount. You want a total for the finished work only, but you're not sure which function does that. You don't need to know the function name. Just tell the AI what's in each column and what result you want.
Watch the video
Ask like this
In Excel, column B says 'Done' or 'In progress' and column C has amounts. Give me one formula that sums C only where B is 'Done', and tell me where to put it.
The answer we got
=SUMIF(B:B,"Done",C:C)It adds up the amounts in column C only for the rows where column B says "Done".| 1 | A Task | B Status | C Amount |
|---|---|---|---|
| 2 | Write report | Done | $1,200 |
| 3 | Research | In progress | $800 |
| 4 | Prep meeting | Done | $500 |
| 5 | Revise design | In progress | $700 |
| 6 | Send quote | Done | $300 |
โ Put =SUMIF(B:B,"Done",C:C) in E1 and you get $2,000 (the total of the 3 Done rows).
Tips for better results
- Two conditions? Use SUMIFS
To total rows that are 'Done' and also named 'Write report', use SUMIFS. Unlike SUMIF, the column you're adding up (C:C) goes first.
=SUMIFS(C:C,B:B,"Done",A:A,"Write report") - Getting 0? Check for spaces and typos
If a cell says 'Done ' with a space at the end, or the word is spelled a little differently, SUMIF skips it. Use TRIM in a spare column to see the cleaned-up value, or ask the AI to 'make it work even if there are extra spaces.'
=TRIM(B2) - Count the Done rows with COUNTIF
To count how many tasks are done instead of adding up amounts, use COUNTIF. With the example table above, it returns 3.
=COUNTIF(B:B,"Done")
Today's checklist
- โ Say what each column contains
- โกUse the exact status text ('Done')
- โขAsk where to put the formula
FAQ
Does the same formula work in Google Sheets?
Yes. SUMIF, SUMIFS and COUNTIF work the same way in Google Sheets. Add "in Google Sheets" to your prompt and the AI will tailor its answer.
Is it OK to use whole columns like B:B?
Yes. With whole columns you can add rows later without editing the formula. Just don't put the total inside column B or C, or the formula ends up including itself. Use an empty cell in another column, as in the example.
AI answers can vary by service and version. Double-check anything important before you use it.
Works in ChatGPT, Claude or Gemini.