How to we exclude a specific name from a DISTINCT LIST USER formula
I would like to exclude a specific user name from this formula.
The formula is working fine, and it is returning a distinct list of user names. However, we need to exclude certain users, that are no longer in the group.
For example, how do I say to exclude user "Joe Black" from this list?
=IFERROR(INDEX(DISTINCT({Trial Lead}), [Unique Row ID]@row, 0), "")
Best Answers
-
Hi @Filippo
You can use a COLLECT Function to filter results, for example:
=IFERROR(INDEX(DISTINCT(COLLECT({Trial Lead}, {Trial Lead}, <> "Joe Black")), [Unique Row ID]@row, 0), "")
An alternative would be to use a Report and Group by the Trial Lead column, ignoring out the users you don't want by adding them to the filter criteria in the Report.
Cheers,
Genevieve
Join us at Smartsheet ENGAGE 2024 🎉
October 8 - 10, Seattle, WA | Register now -
Looks like I missed a closing parenthesis. Sorry about that.
=IFERROR(INDEX(DISTINCT(COLLECT({Project Lead}, {Project Lead}, AND(@cell <> "Joe Black", @cell <> "Jane Doe"))), [Unique Row ID]@row), "")
Answers
-
hi @Filippo try this:
=IFERROR(IF([Trial Lead]@row = "Joe Black", "", INDEX(DISTINCT({Trial Lead}), [Unique Row ID]@row, 0)), "")
-
Nice try Lucas. The issue with this formula, is that the data is coming from another sheet.
The data for "{Trial Lead}" is coming from a different sheet.
While the "[Unique Row ID}" is a helper column in the same sheet I am working on, to auto-number each row.
-
Hi @Filippo
You can use a COLLECT Function to filter results, for example:
=IFERROR(INDEX(DISTINCT(COLLECT({Trial Lead}, {Trial Lead}, <> "Joe Black")), [Unique Row ID]@row, 0), "")
An alternative would be to use a Report and Group by the Trial Lead column, ignoring out the users you don't want by adding them to the filter criteria in the Report.
Cheers,
Genevieve
Join us at Smartsheet ENGAGE 2024 🎉
October 8 - 10, Seattle, WA | Register now -
You would need to include a COLLECT function to filter and then an AND function to create the list of users to skip.
=IFERROR(INDEX(DISTINCT(COLLECT({Trial Lead}, {Trial Lead}, AND(@cell <> "Joe Black", @cell <> "John Smith", @cell <> "Jane Doe")), [Unique Row ID]@row, 0), "")
-
@Paul Newcome the formula provided by Genevieve P. above worked, but it is only good to exclude 1 user. If I have to exclude other users, I have tried to implement the "AND function", as you have indicated, but I get an error saying "#INCORRECT ARGUMENT SET". I bet there is something small to adjust.....what do you think I need to correct?
GOOD Formula for 1 user - need ADD function for multiple users:
=IFERROR(INDEX(DISTINCT(COLLECT({Project Lead}, {Project Lead}, <>"Joe Black")), [Unique Row ID]@row, 0), "")
This is the formula that I had tried, but it gives me the error message (#INCORRECT ARGUMENT SET):
=IFERROR(INDEX(DISTINCT(COLLECT({Project Lead}, {Project Lead}, AND(@cell <> "Joe Black", @cell <> "Jane Doe")), [Unique Row ID]@row, 0), ""))
-
Looks like I missed a closing parenthesis. Sorry about that.
=IFERROR(INDEX(DISTINCT(COLLECT({Project Lead}, {Project Lead}, AND(@cell <> "Joe Black", @cell <> "Jane Doe"))), [Unique Row ID]@row), "")
-
Works perfectly, thank you Paul and Genevieve!!!
-
Happy to help. 👍️
Help Article Resources
Categories
- All Categories
- 14 Welcome to the Community
- Smartsheet Customer Resources
- 62.3K Get Help
- 364 Global Discussions
- 199 Industry Talk
- 428 Announcements
- 4.4K Ideas & Feature Requests
- 136 Brandfolder
- 127 Just for fun
- 128 Community Job Board
- 445 Show & Tell
- 28 Member Spotlight
- 1 SmartStories
- 283 Events
- 35 Webinars
- 7.3K Forum Archives
Check out the Formula Handbook template!