cancel
Showing results for 
Search instead for 
Did you mean: 

Avoid Duplicate in the work queue

davidwarner
Level 2
Hi guys,
I have some work items loaded into the work queue. After some time I need to load a few more work items but it contains some duplicates (which means some items are already there in the work item so I should not load that again) How to find that and load only new items without duplicates.
i want to know this because i am facing problem while working in best affiliate marketing company 
 thank you in advance

------------------------------
david warner
------------------------------
3 REPLIES 3

PabloSarabia
Level 11
Hi @david warner

Use the action "Is Item In Queue" from the Object "Work Queues".

This action returns you a flag indicating if the item exists or not

Your Process should looks like this:

1187.png


In the "check if exists" action stage I call the "Is Item In Queue" action. You can filter here including completed, terminated, deferred and pending items
1188.png

Hope this helps you, and if this solves the problem, remember mark as best answer 😄 



See you in the community, bye 🙂

------------------------------
Pablo Sarabia
Architect
Altamira Assets Management
Madrid
634726270
------------------------------

John__Carter
Staff
Staff
Hi David - just to add to Pablo's good advice, the 'Is Item in Queue' function checks for presence of items that have the Key Value as specified in the input parameter. The Key Value is not necessarily a unique value and it's a common misunderstanding to think that it's like the 'primary key' of a database table. The Key Value is set by you, the solution designer, and it's up to you to decide whether to use a unique value or not, according to your requirements.

Another design decision is consider what to do with the duplicates. Is is OK to simply ignore them and not add them to the queue, as shown in Pablo's example. Maybe this is OK, but it may also be the case that you need to be able to account for all the cases you have been given. For example, suppose the Business give you 1000 cases to work on, and your automation only loads 950 because there were 50 duplicates. Later when the Business asks you for the results of the automation, they will say 'hey this report is wrong, some cases are missing'. You could say 'they were probably duplicates', but it would be better to be able to prove this.

So one option is to add everything to the queue, but put some sort of mark on the duplicate items. Then when the process works the items, it can check for the mark and immediately update a duplicate item as an exception. With this approach you have a record of all cases and cannot be accused of losing anything.

------------------------------
John Carter
Professional Services
Blue Prism
------------------------------

Nice point @John Carter has highlighted .
Also adding into that suggestion is use of priority if we given 1000 cases to work and we find out like 950 are fine and good to move ahead as per BAU. But 50 which is duplicate later can be marked as priority less then those 950 records. And once all BAU is finished mark these 50 one as business exception. This will solve the problem of bot fetching the fresh case every time and at last those are duplicate it will just fetch it and mark it exception and job is done to share with business owner the result which will have all 1000 cases on which Bot worked.  ​

------------------------------
Shikhar Mishra
RPA Lead
Infosys Pvt Ltd
Pune,India
------------------------------
Shikhar Mishra RPA Lead Infosys