Use Excel TEXTJOIN, UNIQUE, and FILTER to Return Groups by Yearly Values
Question details
Return a joined list of unique groups with a matching type and a positive total from Year 2 onward.

- Product
- Microsoft Excel
- Device & OS
- not provided
- Scenario
- The worksheet lists groups in column A, types in column B, and Year 2 through Year 4 values in columns E through G.
- Observed behavior
- The desired result is B / C, excluding Group A because its CAR row has no values after Year 1.
Check that A2:A7 contains group names, B2:B7 contains types, and E2:G7 contains numeric values for Year 2 through Year 4. This formula requires an Excel version that supports FILTER, UNIQUE, and TEXTJOIN.
Filter and Join Unique Groups with a Positive Yearly Total
Use a dynamic array formula to find CAR rows with positive Year 2 through Year 4 totals and join their unique group names.
Click an empty cell where you want the group list to appear.
Type =TEXTJOIN(" / ",TRUE,UNIQUE(FILTER(A2:A7,(B2:B7="CAR")*((E2:E7+F2:F7+G2:G7)>0),""))) and press Enter.
Confirm that the cell displays B / C for the described data. Adjust A2:A7, B2:B7, and E2:G7 to match your worksheet, keeping the ranges aligned.

Find and Join Matching Groups in WPS Spreadsheet
Open your workbook in WPS Spreadsheet and use the same formula to filter CAR rows, remove duplicate groups, and join the results. Your WPS version must support FILTER, UNIQUE, and TEXTJOIN.
- 1. Open the workbook: In WPS Spreadsheet, select Open and choose your Excel workbook.
- 2. Check the columns: Confirm that group names are in A2:A7, types are in B2:B7, and Year 2 through Year 4 values are in E2:G7.
- 3. Enter the formula: Click an empty cell and enter =TEXTJOIN(" / ",TRUE,UNIQUE(FILTER(A2:A7,(B2:B7="CAR")*((E2:E7+F2:F7+G2:G7)>0),""))).
- 4. Review and save: Press Enter, check the result, and use File > Save As to save the workbook in XLSX format.

Frequently Asked Questions
Why is Group A excluded?
Its CAR row has no values after Year 1, so its Year 2 through Year 4 total is not greater than zero.
How can I filter for a different type?
Replace "CAR" in the B2:B7="CAR" condition with the type you want, such as "TRUCK".
What happens if no rows meet the conditions?
The formula uses an empty string as FILTER's if_empty argument, so TEXTJOIN returns a blank result.
Does the formula add values across multiple rows for the same group?
No. It tests each row's Year 2 through Year 4 total separately, then returns each matching group name once.
Why does the formula return a function error?
Check that your spreadsheet version supports FILTER, UNIQUE, and TEXTJOIN, and that the Year 2 through Year 4 cells contain numbers or blanks rather than text.




