# Remove duplicates from list

**URL:** <https://forum.dynamobim.com/t/remove-duplicates-from-list/33541>\
**Category:** Lists-Logic\
**Tags:** revit\
**Created:** [March 15, 2019, 3:21pm UTC](https://forum.dynamobim.com/t/remove-duplicates-from-list/33541 "2019-03-15T15:21:03Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![frenga](https://avatars.discourse-cdn.com/v4/letter/f/48db29/32.png) [@frenga](https://forum.dynamobim.com/u/frenga)\
**Post date:** [March 15, 2019, 3:21pm UTC](https://forum.dynamobim.com/t/remove-duplicates-from-list/33541/1 "2019-03-15T15:21:03Z")

</div>

I’m having difficulties figuring out how to remove duplicate items from my list. To clarify, I need the duplicate items (and singular items) to appear only once. Per my image below (one example) my list is populated with the same parameter multiple times (item#2 and item#46) and I’d like only one instance of that parameter to appear. I’ve tried figuring out how to handle this with a boolean filter but am not sure how to proceed with that logic. I’m on dynamo 2.0 and thanks in advance!

 ![image](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/5/e/5e88617eaceda0d77bee95216ee59b6e4265ada3.png)

---

<div class="post-metadata">

**Author:** ![Sorin\_T](https://avatars.discourse-cdn.com/v4/letter/s/e8c25b/32.png) [@Sorin\_T](https://forum.dynamobim.com/u/Sorin_T)\
**Post date:** [March 15, 2019, 3:29pm UTC](https://forum.dynamobim.com/t/remove-duplicates-from-list/33541/2 "2019-03-15T15:29:06Z")

</div>

Hello, for list-logic you can use the list.UniqueItems node that outputs only the first occurrence of an item in a list and discards the rest.

Edit\*

In your case here the duplicate parameters are actually different parameters with their own id so the UniqueItems node probably won`t work.

---

<div class="post-metadata">

**Author:** ![Sorin\_T](https://avatars.discourse-cdn.com/v4/letter/s/e8c25b/32.png) [@Sorin\_T](https://forum.dynamobim.com/u/Sorin_T)\
**Post date:** [March 15, 2019, 3:47pm UTC](https://forum.dynamobim.com/t/remove-duplicates-from-list/33541/3 "2019-03-15T15:47:02Z")

</div>

Try this workaround

 ![Capture](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/a/b/ab09b8a57199e75e251c4cb679b03608e18c09b2.png)

---

<div class="post-metadata">

**Author:** ![frenga](https://avatars.discourse-cdn.com/v4/letter/f/48db29/32.png) [@frenga](https://forum.dynamobim.com/u/frenga)\
**Post date:** [March 15, 2019, 3:56pm UTC](https://forum.dynamobim.com/t/remove-duplicates-from-list/33541/4 "2019-03-15T15:56:23Z")

</div>

Thanks for the quick response Sorin but yes I tried the UniqueItems node and that didn’t work for me. My understanding of the UniqueItems node is that the output only displays items unique in the list so if there are duplicates, all of those items are removed (please correct me if I’m wrong). In this case the unique elements node doesn’t remove any items from my list. See snipit below. I did confirm that the parameters across these elements are using the same shared parameter so that adds confusion to what I thought was logical.

 ![image](https://us1.discourse-cdn.com/flex022/uploads/dynamobim/original/3X/5/a/5a841e3e3869e266bfc009c7ff81cc14545c796b.png)

---

<div class="post-metadata">

**Author:** ![frenga](https://avatars.discourse-cdn.com/v4/letter/f/48db29/32.png) [@frenga](https://forum.dynamobim.com/u/frenga)\
**Post date:** [March 15, 2019, 3:59pm UTC](https://forum.dynamobim.com/t/remove-duplicates-from-list/33541/5 "2019-03-15T15:59:15Z")

</div>

I’m going to try that now and will report back shortly. Thanks again for the quick response (it was quicker than my reply)!

---

<div class="post-metadata">

**Author:** ![frenga](https://avatars.discourse-cdn.com/v4/letter/f/48db29/32.png) [@frenga](https://forum.dynamobim.com/u/frenga)\
**Post date:** [March 15, 2019, 5:15pm UTC](https://forum.dynamobim.com/t/remove-duplicates-from-list/33541/6 "2019-03-15T17:15:24Z")

</div>

It appears for my specific situation that once my list was converted to string that the unique items node did the trick all on its own! Much appreciation Sorin!

---

<div class="post-metadata">

**Author:** ![pics.munmun](https://avatars.discourse-cdn.com/v4/letter/p/b9e5f3/32.png) [@pics.munmun](https://forum.dynamobim.com/u/pics.munmun)\
**Post date:** [April 27, 2023, 4:19am UTC](https://forum.dynamobim.com/t/remove-duplicates-from-list/33541/7 "2023-04-27T04:19:04Z")

</div>

Any update on this functionality. I am facing the same issue
