Here I have created sample that will help you out.
C#
protected void Page_Load(object sender, EventArgs e)
{
bool IsMatchedFirstColumn = GetCSVDiff(Server.MapPath("CSVs/1.csv"), Server.MapPath("CSVs/2.csv"), 1);
bool IsMatchedSecondColumn = GetCSVDiff(Server.MapPath("CSVs/1.csv"), Server.MapPath("CSVs/2.csv"), 2);
}
private bool GetCSVDiff(string firstFile, string secondFile, int columnIndex)
{
bool isColumnMatched = true;
columnIndex = columnIndex - 1;
int i = 0;
foreach (var fileoneline in File.ReadAllLines(firstFile))
{
int j = 0;
foreach (var line in File.ReadAllLines(secondFile))
{
if (i == j)
{
var fields = line.Split(new char[] { ';' }, 2);
if (fileoneline.Split(';')[0].Split(',')[columnIndex].Trim() != fields[0].Split(',')[columnIndex].Trim())
{
isColumnMatched = false;
break;
}
}
j++;
}
i++;
}
return isColumnMatched;
}
1.csv
1,2,3,4
2,2,3,4
2.csv
1,2,3,4
2,3,3,4
Screenshot