# How to remove duplicate values from each page in pagelist

**URL:** <https://forums.pega.com/t/how-to-remove-duplicate-values-from-each-page-in-pagelist/3305>\
**Category:** User Experience\
**Tags:** dev-designer-studio, user-experience, pega-platform\
**Created:** [October 3, 2022, 8:35am UTC](https://forums.pega.com/t/how-to-remove-duplicate-values-from-each-page-in-pagelist/3305 "2022-10-03T08:35:27Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![SwathiM5232](https://avatars.discourse-cdn.com/v4/letter/s/3ec8ea/32.png) [@SwathiM5232](https://forums.pega.com/u/SwathiM5232)\
**Post date:** [October 3, 2022, 8:35am UTC](https://forums.pega.com/t/how-to-remove-duplicate-values-from-each-page-in-pagelist/3305/1 "2022-10-03T08:35:27Z")

</div>

Hi All,

I have the below requirement

Pagelist.pxResults(1).pyText = [test@gmail.com](mailto:test@gmail.com);test1@gmail.com

pagelist.pxResults(2).pyText = [test@gmail.com](mailto:test@gmail.com);test1@gmail.com;test2@gmail.com

I want to retrieve only unique values from above results [test@gmail.com](mailto:test@gmail.com);test1@gmail.com;test2@gmail.com

Tried @pyRemoveDuplicatesFromPagelist , it removes duplicates only if all the values in both the pages matches . So in my case its not working.

Please help me with the above requirement

Thanks

---

<div class="post-metadata">

**Author:** ![ArulDevan](https://yyz2.discourse-cdn.com/pega/user_avatar/forums.pega.com/aruldevan/32/23602_2.png) [@ArulDevan](https://forums.pega.com/u/ArulDevan)\
**Post date:** [October 3, 2022, 8:46am UTC](https://forums.pega.com/t/how-to-remove-duplicate-values-from-each-page-in-pagelist/3305/2 "2022-10-03T08:46:50Z")

</div>

Hi @SwathiM5232: There is no OOTB feature available to do this. You can still achieve this programmatically

1. Loop through your page list
2. Tokenize the string based on delimiter and append the results to a new page list
3. Remove duplicates from the new page list

Thanks

---

<div class="post-metadata">

**Author:** ![SwathiM5232](https://avatars.discourse-cdn.com/v4/letter/s/3ec8ea/32.png) [@SwathiM5232](https://forums.pega.com/u/SwathiM5232)\
**Post date:** [October 3, 2022, 9:06am UTC](https://forums.pega.com/t/how-to-remove-duplicate-values-from-each-page-in-pagelist/3305/3 "2022-10-03T09:06:14Z")

</div>

@ArulDevan Hi Arul thanks for your reply.

I didnt understand step 2 .Could you pls share screenshot if any. It would be helpful

Many Thanks

---

<div class="post-metadata">

**Author:** ![ArulDevan](https://yyz2.discourse-cdn.com/pega/user_avatar/forums.pega.com/aruldevan/32/23602_2.png) [@ArulDevan](https://forums.pega.com/u/ArulDevan)\
**Post date:** [October 3, 2022, 9:22am UTC](https://forums.pega.com/t/how-to-remove-duplicate-values-from-each-page-in-pagelist/3305/4 "2022-10-03T09:22:16Z")

</div>

Hi @SwathiM5232: Sorry. I don’t have docs for this. Let me try to explain.

Within the loop you need to split pyText based on the delimiter (semi colon in this scenario) and can append it to a page list. To do this, you can either create a function (similar to pxParsepxResults) or can use Parse-delimited.

Once you have the page list, then you can remove duplicate from it.

Please let me know if this helps.

Thanks.

---

<div class="post-metadata">

**Author:** ![SwathiM5232](https://avatars.discourse-cdn.com/v4/letter/s/3ec8ea/32.png) [@SwathiM5232](https://forums.pega.com/u/SwathiM5232)\
**Post date:** [October 3, 2022, 7:50pm UTC](https://forums.pega.com/t/how-to-remove-duplicate-values-from-each-page-in-pagelist/3305/5 "2022-10-03T19:50:49Z")

</div>

@ArulDevan Hi Arul.. Thanks for the clarification

As Suggested by you , I have created parse delimited rule similar to above and the results are getting stored into a value list (.IMOEmailList)

.IMoEmailList(1) , (2)…etc

Now how do we set this value list to a pagelist in activity.

Pls suggest.

Many Thanks

---

<div class="post-metadata">

**Author:** ![ArulDevan](https://yyz2.discourse-cdn.com/pega/user_avatar/forums.pega.com/aruldevan/32/23602_2.png) [@ArulDevan](https://forums.pega.com/u/ArulDevan)\
**Post date:** [October 4, 2022, 1:58am UTC](https://forums.pega.com/t/how-to-remove-duplicate-values-from-each-page-in-pagelist/3305/6 "2022-10-04T01:58:31Z")

</div>

Hi @SwathiM5232: You can loop through the value list in activity using for each element in value list.

Another suggestion: instead of doing the parse delimited for each loop, build a single sting with all pyText and use Parse-delimited once.

Thanks

---

<div class="post-metadata">

**Author:** ![SwathiM5232](https://avatars.discourse-cdn.com/v4/letter/s/3ec8ea/32.png) [@SwathiM5232](https://forums.pega.com/u/SwathiM5232)\
**Post date:** [October 7, 2022, 6:48am UTC](https://forums.pega.com/t/how-to-remove-duplicate-values-from-each-page-in-pagelist/3305/7 "2022-10-07T06:48:37Z")

</div>

@ArulDevan Thanks Arul , 2nd option helped
