I have a file in the below format:
Name=Dan
Age=45
Name=Alex
Age=35
Cellphone=12345678901
Name=John
Age=
Cellphone=12345678901
This file has got 1000's of data items in above format, Name=Value.
If values are missing, and I want to find these in below output as missing value for Age.
I tried by using the cut command, cut -d “=“ -f2 > some file, then grep for an empty line, grep -n ‘[[:blank:]]’ file, then display the line number in the original file.
But since I have multiple files, this method looks complicated.
Is there any simpler method for this?