I want to check two data frames records if they are same if not same then filter out the records and save the records in excel files.
for example if ANA2719 is not available in df2 but available in df then filter out the row and save as xlsx file
vise versa for the same KTN2542 is not present in df2 but present in DF then filter out the whole row and save as xlsx file
Note: weather any column can be lower case or upper . i mean it should also take care of upper case and lower case
df <- data.frame(ID =c("DEV2962","KTN2252","ITI2624","DEV2698","HRT2921","","KTN2624","ANA2548","ITI2535","DEV2732","HRT2837","ERV2951","KTN2542","ANA2813","ITI2210","KTN2542"),
city=c("DEL","mum","MUM","DEL","del","MUM","DEL","del","MUM","mum","mum","mum","mum","DEL","DEL","mum"),
Name= c("dev,akash","singh,rahul","lal,ram","singh,nkunj","garg,prabal","ali,sanu","singh,kunal","tomar,lakhan","thakur,praveen","ali,sarman","khan,zuber","singh,giriraj","sharma,lokesh","pawar,pooja","sharma,nikita","shivam"))
df2 <- data.frame(ID =c("DEV2962","KTN2251","ANA2719","ITI2624","DEV2698","HRT2923","","KTN2624","ANA2548","ITI2535","DEV2732","HRT2837","ERV2951","KTN2542","ANA2813","ITI2210"),
city=c("DEL","mum","DEL","MUM","DEL","del","MUM","DEL","del","MUM","mum","mum","mum","mum","DEL","DEL"),
Name= c("dev,akash","singh,rahul","abbas,salman","lal","singh,nkunj","garg","ali,sanu","singh,kunal","tomar,lakhan","thakur,praveen","ali,sarman","khan,zuber","singh,giriraj","sharma,lokesh","pawar,pooja","sharma,nikita"))
the output i want to save in excel file as "records not in df"
in second sheet , list of records output "records not in df2"