# Queue Reference question?

**URL:** <https://forum.uipath.com/t/queue-reference-question/367011>\
**Category:** Studio\
**Tags:** add-queue-item, queue-processing, queue, orchestrator, system, activities\
**Created:** [December 3, 2021, 8:24pm UTC](https://forum.uipath.com/t/queue-reference-question/367011 "2021-12-03T20:24:21Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![RPA708](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/rpa708/32/265973_2.png) [@RPA708](https://forum.uipath.com/u/RPA708)\
**Post date:** [December 3, 2021, 8:24pm UTC](https://forum.uipath.com/t/queue-reference-question/367011/1 "2021-12-03T20:24:21Z")

</div>

I’ve checked the Reference box in creating a queue, created a unique reference in Add Queue Items with Looping through my database data table id’s with a For Each and assigning CurrentRow(“id”).ToString.  
It is then assigning all my data table id’s to my queue transactions.  
I’ve gone ahead and then assigned both of the lists to List of Strings.  
Im then comparing the Lists for an uncommon id and getting a value. Number 13.  
My question is how do i assign the id’s to the reference and after the initial id’s have been created when I make additional id’s to my “database id’s” only adding the different value?  
Or is there an easier way to do this…?  
Thanks in advance

 ![Screen Shot 2021-12-03 at 12.11.33 PM](https://global.discourse-cdn.com/uipath/original/4X/8/b/2/8b2043e70e06c5492203f7c2b160dd4c630be3cf.png)

---

<div class="post-metadata">

**Author:** ![svillalobos](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/svillalobos/32/288682_2.png) [@svillalobos](https://forum.uipath.com/u/svillalobos)\
**Post date:** [December 3, 2021, 8:48pm UTC](https://forum.uipath.com/t/queue-reference-question/367011/2 "2021-12-03T20:48:58Z")

</div>

Hi,

I think question may be answered on this post. Otherwise, let us know.

> [@How to use Queue Unique Reference?](https://forum.uipath.com/t/how-to-use-queue-unique-reference/62526):
>
> I’m trying to load a queue with some items, and I am trying to store the reference as the ID number of the transaction so that I can use that reference in the future, to know if the Queue already has that item. How do I store the ID Number as the reference. I am totally confused overall about the Queue reference, so any explanations would be appreciated. A nice picture, explaining in detail how the queue reference works would be awesome. I already have my Queue set up for Unique references in O…

In the orchestrator queue you can flag that only unique reference are allowed to be added.

 ![Screen Shot 2021-12-03 at 14.47.25](https://global.discourse-cdn.com/uipath/original/4X/1/0/4/1048da46a9f717375b33eb06c6f97456826ba12c.png)

---

<div class="post-metadata">

**Author:** ![Jobin\_Joy](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/jobin_joy/32/555040_2.png) [@Jobin\_Joy](https://forum.uipath.com/u/Jobin_Joy)\
**Post date:** [December 4, 2021, 4:53am UTC](https://forum.uipath.com/t/queue-reference-question/367011/3 "2021-12-04T04:53:19Z")

</div>

Hi @RPA708

Welcome to UiPath Forum.

Adding references to transaction item is enforced to be unique at the queue level. This feature is enabled when creating the queue and applies to all transactions except deleted or retried ones.

Main reason reason behind adding reference is, if a duplicate reference is encountered while adding items to a queue, the job fails with a Faulted status and displays the Execution error: UiPath.Core.Activities.OrchestratorHttpException: Error creating Transaction. Duplicate Reference. error message in the Job Details window.

Coming back to your question, to assign ids/or unique keys as a reference you can to generate it just before executing the ‘Add Queue Item’ activity and if you are adding additional ids(reference), the queue item will be added if it’s not duplicate.

Hope this will be useful. Thank you.

---

<div class="post-metadata">

**Author:** ![RPA708](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/rpa708/32/265973_2.png) [@RPA708](https://forum.uipath.com/u/RPA708)\
**Post date:** [December 4, 2021, 4:28pm UTC](https://forum.uipath.com/t/queue-reference-question/367011/4 "2021-12-04T16:28:40Z")

</div>

After some digging I found a solution on this post:  
[Continue on error](https://forum.uipath.com/t/how-to-add-unique-values-in-queue-by-add-queue-items/328618)

Thank you gentlemen for your assistance.

---

<div class="post-metadata">

**Author:** ![svillalobos](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/svillalobos/32/288682_2.png) [@svillalobos](https://forum.uipath.com/u/svillalobos)\
**Post date:** [December 4, 2021, 8:12pm UTC](https://forum.uipath.com/t/queue-reference-question/367011/5 "2021-12-04T20:12:09Z")

</div>

Glad you were able to find the answer to your question.

Welcome to the UiPath Community 🙂

---

<div class="post-metadata">

**Author:** ![Jobin\_Joy](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/jobin_joy/32/555040_2.png) [@Jobin\_Joy](https://forum.uipath.com/u/Jobin_Joy)\
**Post date:** [December 5, 2021, 3:11am UTC](https://forum.uipath.com/t/queue-reference-question/367011/6 "2021-12-05T03:11:36Z")

</div>

Hi @RPA708

Glad to hear that your issue has been resolved. Thank you.

---

<div class="post-metadata">

**Author:** ![RPA708](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/rpa708/32/265973_2.png) [@RPA708](https://forum.uipath.com/u/RPA708)\
**Post date:** [December 10, 2021, 6:29pm UTC](https://forum.uipath.com/t/queue-reference-question/367011/7 "2021-12-10T18:29:50Z")

</div>

Cheers, Thank you!

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/uipath/user_avatar/forum.uipath.com/system/32/182466_2.png) [@system](https://forum.uipath.com/u/system)\
**Post date:** [December 13, 2021, 6:30pm UTC](https://forum.uipath.com/t/queue-reference-question/367011/8 "2021-12-13T18:30:14Z")

</div>

Closed on December 13, 2021, 6:30pm UTC

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