I have a file that contains lines that look like the following:
I want to remove all instances in the file with the null as the last term. Is there a way to do this with Unix commands?
I was going to read in the file with Java and look at adjacent lines and remove the line whose adjacent line has similar first two terms but null as the third term. Is there a way to do this through Unix tools?
Edit: I don't want to blindly remove all of the terms with null as the third term, I might have the following entry: 15|lsu|null I'd like to keep it since it is the only entry. It's just that, if there is another line with a third term that is non-null, I would like to keep the non-null value.