# Comparing Lists inside a row

**URL:** <https://connect.superhuman.com/t/comparing-lists-inside-a-row/26399>\
**Category:** Ask the Community\
**Created:** [October 22, 2021, 3:13am UTC](https://connect.superhuman.com/t/comparing-lists-inside-a-row/26399 "2021-10-22T03:13:52Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Robin\_Bigio](https://yyz1.discourse-cdn.com/coda1/user_avatar/connect.superhuman.com/robin_bigio/32/17345_2.png) [@Robin\_Bigio](https://connect.superhuman.com/u/Robin_Bigio)\
**Post date:** [October 22, 2021, 3:13am UTC](https://connect.superhuman.com/t/comparing-lists-inside-a-row/26399/1 "2021-10-22T03:13:52Z")

</div>

Hi there, I am trying to compare two lists inside a row.

Here is a simplified doc:  
[https://coda.io/d/Compare-Items-in-a-Cell\_d6N-Q\_ofrDS](https://coda.io/d/Compare-Items-in-a-Cell_d6N-Q_ofrDS)

What I am hoping to get is which values are not in the second column, see the screenshot below:

 ![Screen Shot 2021-10-21 at 8.12.59 PM](https://global.discourse-cdn.com/coda1/original/3X/1/9/19c83d9cb3cf0cfe9c424e1d66a1a8441b3c1ec3.png)

I found this but it does not seem to work: [Shishir's Coda Community Tips and Tricks](https://coda.io/d/Shishirs-Coda-Community-Tips-and-Tricks_dpuW8RMd8fq/04-07-19-Difference-Between-Two-Lists_susCa?utm_campaign=embed&utm_medium=web&utm_source=puW8RMd8fq#_luF3z)

Thanks for your help!

---

<div class="post-metadata">

**Author:** ![Christiaan\_Huizer](https://yyz1.discourse-cdn.com/coda1/user_avatar/connect.superhuman.com/christiaan_huizer/32/28269_2.png) [@Christiaan\_Huizer](https://connect.superhuman.com/u/Christiaan_Huizer)\
**Post date:** [October 22, 2021, 6:08am UTC](https://connect.superhuman.com/t/comparing-lists-inside-a-row/26399/2 "2021-10-22T06:08:44Z")

</div>

hi @Robin_Bigio , good question!

I could not access your doc, so I recreated it rapidly on my side,below the screenshots and the formula I applied:

 ![image](https://global.discourse-cdn.com/coda1/original/3X/f/d/fd06f30cc0f977673fab43bf7afbfe9fe1f33d79.png)

`thisRow.[List 1].Filter(CurrentValue.Contains(thisRow.[list 2]).Not())`

best, Christiaan

---

<div class="post-metadata">

**Author:** ![Robin\_Bigio](https://yyz1.discourse-cdn.com/coda1/user_avatar/connect.superhuman.com/robin_bigio/32/17345_2.png) [@Robin\_Bigio](https://connect.superhuman.com/u/Robin_Bigio)\
**Post date:** [October 22, 2021, 1:51pm UTC](https://connect.superhuman.com/t/comparing-lists-inside-a-row/26399/3 "2021-10-22T13:51:45Z")

</div>

@Christiaan_Huizer, that totally worked! Thanks so much!

Can you explain why? I am not sure I get it…

---

<div class="post-metadata">

**Author:** ![Christiaan\_Huizer](https://yyz1.discourse-cdn.com/coda1/user_avatar/connect.superhuman.com/christiaan_huizer/32/28269_2.png) [@Christiaan\_Huizer](https://connect.superhuman.com/u/Christiaan_Huizer)\
**Post date:** [October 22, 2021, 2:12pm UTC](https://connect.superhuman.com/t/comparing-lists-inside-a-row/26399/4 "2021-10-22T14:12:44Z")

</div>

hi @Robin_Bigio , great that it works 😉

in the column ‘List 1’ you have on the first row a list with 4 items. Each item is evaluated via the filter as ‘CurrentValue’ to see if it contains a value that lives in Column _List 2_. The Filter first checks item 1 (which is the first currentvalue) and checks if it lives in List 2, then it checks item 2 (the 2nd currentvalue) to see if this one lives in List 2 and so on.

Without the Not() you would have as result ‘item 2’, but you needed the difference, so we turned the result upside down and instead asked for ‘contains not’ you write as `Contains().Not().`

I hope it helps a bit.

last but not least, would you be so kind to mark my contribution as solution, that is mainly important for those who provide support of all sorts (for free).

Enjoy your day, Christiaan

---

<div class="post-metadata">

**Author:** ![Robin\_Bigio](https://yyz1.discourse-cdn.com/coda1/user_avatar/connect.superhuman.com/robin_bigio/32/17345_2.png) [@Robin\_Bigio](https://connect.superhuman.com/u/Robin_Bigio)\
**Post date:** [October 22, 2021, 3:57pm UTC](https://connect.superhuman.com/t/comparing-lists-inside-a-row/26399/5 "2021-10-22T15:57:16Z")

</div>

Amazing, thanks so much!

---

<div class="post-metadata">

**Author:** ![system](https://yyz1.discourse-cdn.com/coda1/user_avatar/connect.superhuman.com/system/32/24484_2.png) [@system](https://connect.superhuman.com/u/system)\
**Post date:** [October 25, 2021, 3:57pm UTC](https://connect.superhuman.com/t/comparing-lists-inside-a-row/26399/6 "2021-10-25T15:57:43Z")

</div>

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.
