Skip to main content
Question

Duplicate entries in excel


Forum|alt.badge.img+5
  • Navigator | Tier 3
  • 22 replies

Hi,

I have two excel files , in the first one there are some document no’s which i need to pickup one by one & find them in the other excel, if a match is found then I need to log it.

The problem is that the doc no’s in the first excel can get repeated any number of times and if a match is found then it should continue to pickup the next record, although there can be a possibility that the next record can be the same doc no as the above, refer to the screenshot below :

 

So according to the above image, the bot should pickup the first record (14669), if match is found then it should ignore the rest of the 3 records and pickup the next record.

 

How can this be achieved? Any help would be appreciated :)

3 replies

Forum|alt.badge.img+6
  • Navigator | Tier 3
  • 142 replies
  • August 25, 2023

Maintain a list of already actioned items, check if current item is already actioned and skip the iteration.

Loop each row in excel
 if current item exist in actioned items
 continue
.
… other processing steps
.
add current item to actioned list
end excel loop


Forum|alt.badge.img+5
  • Author
  • Navigator | Tier 3
  • 22 replies
  • August 28, 2023
Sumit.K7 wrote:

Maintain a list of already actioned items, check if current item is already actioned and skip the iteration.

Loop each row in excel
 if current item exist in actioned items
 continue
.
… other processing steps
.
add current item to actioned list
end excel loop

Hi Sumit,

Thanks for your reply. I have to pick up records one by one from one excel and match them from the other excel, so how can i already prepare a list of actioned items beforehand. The continuing of the loop has to be on the fly if it finds a duplicate.


Forum|alt.badge.img+1
  • Cadet | Tier 2
  • 4 replies
  • September 6, 2023

Hello, 

 

Step 1, Use Excel Advance: Get multiple cells , and assign the value to a “Table” Variable; 

Step 2, Use Data Table: Remove Duplicate Rows, to remove the duplicate rows in that “Table” Variable;

tips:

you may also need to count the rows of the “Table” after step2, to get the actual distinct number or rows for the “Table” variable, which count can be used in next Loop step to Find the matching rows in the second Excel file. 


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings