File1: a.txt
$ cat a.txt
ABC|1|11|3333|dog
ABC|1|11|3333|dig
ABC|1|11|3633|dug
ABC|2|11|3333|cat
File2: b.txt
$ cat b.txt
ABC|1|12|3333|dog
ABC|1|11|3333|dig
ABC|7|11|3633|dag
ABC|2|11|3373|cat
I want to find differences where the line is listed, position from to is listed and the string value is listed between the two files where the difference occurs.
I tried your approach, and it gives me differences by lines but imagine if there are 100 delimited columns in a line, how would one find what value(s) are differing. In above two text files, in line 3 there are two differences. The result set does not give both differences but rather stating line number as a difference.
$ diff -e a.txt b.txt
3,4c
ABC|7|11|3633|dag
ABC|2|11|3373|cat
.
1c
ABC|1|12|3333|dog
.