Compare two csv files

i would like to get some help on how to compare two csv files.
basically i need to make sure that one user name do not exist on the active csv file, for me to delete it from the gmail domain. i have to delete old email accounts that are not active anymore.

Hi @Jorge12 welcome to forum
can u elaborate ur query with screenshots?

the website do not allow me to send screen shot.
you can see that one file has three user names that means that i have to high light all the extra user names and then delete those accounts because they are not in use anymore.
that is just an example. i have a list of 1800 username that i have to revised.

Hi @Jorge12 so in general u have two csv files, one is updated with new and other one with old data
so ur main requirment is to remove the old data from updated csv file
is it right?

Hello, yes you are correct.
I also had a question would it be easier to convert the csv file to excel file?

Hi @Jorge12

Then u can compare the 2 CSV files through this way

  1. Read the CSV files and store in datatable format

  2. Compare two datatable by using linq query

Link below for the linq query

  1. Using the linq query get the unmatched data ( which is the new data ) and store in datatable let’s say dt_result

  2. Then write the dt_result to an Excel file

Hope the above logic helps you

Mark it as solution if you got it

Regards

Nived N :robot:

Happy Automation :slight_smile::slight_smile::slight_smile::slight_smile::slight_smile::slight_smile: