I have a requirement to match column 4 (Grade) from File1 csv with column 1 (Grade) of File2 , if. If it matches then, replace column 4 (Grade) of File1 csv with Column2column2 (Marks) of File2. if not matchesIf it doesn't match, then leave previousthe value of column 4 (Grade) as is.
File1
"RollNo","Name","Age","Grade","Class","Teacher"
"1","Asha","7","A","1","David"
"2","Mona","7","B","1","David"
"3","Sonali","7","C","1","David"
"4","Rani","7","D","1","David"
"5","Raj","7","B","1","David"
"RollNo","Name","Age","Grade","Class","Teacher" "1","Asha","7","A","1","David" "2","Mona","7","B","1","David" "3","Sonali","7","C","1","David" "4","Rani","7","D","1","David" "5","Raj","7","B","1","David" File2
"Grade","Marks"
"A","90"
"B","80"
"C","70"
"Grade","Marks" "A","90" "B","80" "C","70" Expected Outputoutput:
"RollNo","Name","Age","Grade","Class","Teacher"
"1","Asha","7","90","1","David"
"2","Mona","7","80","1","David"
"3","Sonali","7","70","1","David"
"4","Rani","7","D","1","David"
"5","Raj","7","80","1","David"
"RollNo","Name","Age","Grade","Class","Teacher" "1","Asha","7","90","1","David" "2","Mona","7","80","1","David" "3","Sonali","7","70","1","David" "4","Rani","7","D","1","David" "5","Raj","7","80","1","David" Can you please help me with howan awk command should be for this Output output?
Looking ahead for your response.