Queue unique reference

Hi,
When I am trying to add a queue item with unique reference set, if it is added for the second time, the bot is throwing an error, How to work with this error in REFRanework. I only want the bot to add new items to quuee and ignore already added items,

Thank you,

Hi @A_Learner

Could you please share the error here what you are exactly getting.

Add Queue Item: Error creating transaction. Duplicate reference error code:1016

Hi @A_Learner

The bot will receive the error code 1016 (DuplicateReference). So you can surround the Add Queue Item activity with Try Catch then treat the error code in Exception, ignoring the error, reponse to source system about the duplicate etc

Orchestrator response codes

Cheers

Henrique Lima

Another solution - you could use the “Get Queue Items” activity to check for existing items with the reference. Only if the result is 0, proceed with adding to queue.

Thank you, @efelantti
Can you put the code segment here?

Thank you,

While you are creating the queue in Orchestrator. If you checked the Enforce Unique reference option then it will not allow you to add duplicate reference queues into it.

Uncheck the option and then try it will add the queues with same reference for sure.

Check the below image for better understanding,

Hope you understand!!

Hi @A_Learner

The attached workflow contains both strategies

DuplicateReference.zip (4.7 KB)

2 Likes

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