Sum Column E Amounts When Column F Equals 40 in WPS Spreadsheets
Question details
Add the amounts in Column E for every row whose corresponding value in Column F is 40.

- Product
- WPS Spreadsheets or Microsoft Excel workbook
- Device & OS
- not provided
- Scenario
- The user needs a conditional total based on a numeric value in another column.
- Observed behavior
- The desired result is one total that includes only Column E amounts from rows where Column F equals 40.
Confirm that Column F contains real numeric values, not text such as "40" with leading spaces. Choose an empty cell for the result so the formula does not overwrite worksheet data.
Use SUMIF to total Column E when Column F is 40
Use this method when one condition determines which amounts to add.
SUMIF checks the criteria range in Column F and adds the matching values from Column E. The formula returns a single total for all rows that meet the condition.
Click an empty cell where you want the conditional total to appear, such as G2.
Type =SUMIF(F:F,40,E:E) in the selected cell or in the formula bar.
Press Enter. WPS Spreadsheets adds all values in Column E whose matching cells in Column F equal 40.

Use SUMIFS when the total needs additional conditions
Use SUMIFS when Column F must equal 40 and another column must also meet a criterion, such as a date, category, or status.
Summarize amounts by Column F value with a PivotTable
Use a PivotTable when you want to view totals for 40 and other values in Column F at the same time.
Calculate Conditional Totals with SUMIF in WPS Spreadsheets
WPS Spreadsheets lets you use the familiar SUMIF formula to total values in one column when a matching column contains 40. Enter the formula in any result cell, then update the criteria or ranges as your worksheet grows.
- 1. Open the worksheet: Open your .xlsx or .xls file in WPS Office and select WPS Spreadsheets.
- 2. Choose a result cell: Click an empty cell outside Columns E and F where you want the total displayed.
- 3. Enter the formula: Type =SUMIF(F:F,40,E:E) in the cell or Formula Bar.
- 4. Calculate the total: Press Enter to show the sum of Column E amounts for rows with 40 in Column F.

Frequently Asked Questions
What does =SUMIF(F:F,40,E:E) mean?
F:F is the range WPS Spreadsheets checks, 40 is the required value, and E:E is the range of amounts to add when the same-row value in Column F is 40.
Why does SUMIF return 0 when I can see 40 in Column F?
The 40 values may be stored as text or contain hidden spaces. Select the cells in Column F, use Data tools or formatting to convert them to numbers, and then recalculate the formula.
Can I use cell references instead of typing 40 in the formula?
Yes. If cell H1 contains 40, enter =SUMIF(F:F,H1,E:E). This makes the total change automatically when you replace the value in H1.
How do I total only rows where Column F is 40 and Column G is Approved?
Use SUMIFS, such as =SUMIFS(E:E,F:F,40,G:G,"Approved"). The first range, E:E, is the amount range to total.
Does the SUMIF formula work in Excel files opened with WPS Spreadsheets?
Yes. SUMIF is compatible with common Microsoft Excel .xlsx and .xls workbook formats, so the formula can be used and saved in those files.




