How to compare records of two excel

Hi all,

I am working on a scenario where I have two excel sheets, One sheet contain 29k records and the other one contains 3k records. I want to compare 29k records one by one with 3k records.
For now I am reading both sheets by using read range,
using for each and iterating through excel of 29k records.
again using for each and iterating through records of 3k records.

but it is just comparing 29k records with just one record of sheet 3k record.

any help in this regard in appreciated.

thank you

Hi @enthusiastic

The following resource might help you with this:

Best Regards.

Hi @enthusiastic

Iterating the datatable and comparing is much difficult. If you use the linq queries it will take less time to filter and compare if the excel have many rows.

Hope it helps!!

do help with linq query

@enthusiastic
For that please provide the filtration details. Then it will help me to write the linq querey.

if the datarow from the below mentioned columns
of dtresult match with the datatow of columns of dtexclusions i need to data matched in the new excel file

datatable name dtresult

Firstname
Lastname
DOB
NPI

datatable name dtexclusions

Firstname
Lastname
Date of Birth
NPI Number

and moreover i want to assign this linq query to a boolean variable, i dnt want to assign it to a datatable