Using grep and a parameter file to return unique values

Hello Lucas,

Thanks again for your help!

It works with data1-2.txt, but then if I change '3078=' to '5022=", it returns the below:

I tried to re-arrange the command but with no success :frowning:

1 Like

why you change '3078=' to '5022=', you always change what you expected, of cause a solution to one problem could not solve another problem.

I use pattern |3078= not 3078=
there is not a | before 5022=. so your changes not works for you.

Hi Lucas,

I don't change it for fun!

it is because sometimes the pattern changes: 3078= and 4=* can be anywhere on one line :frowning:

I was only trying to find out why what you wrote returned so few results when I run it against the 1 GB directory. I sincerely appreciate your help, it is a really difficult problem :frowning:

In the previous awk scripts you can exchange the /|3078=/ or $0~/|3078=/ by "|"$0~/|3078=/ ,
then the search works for any field including field#1.

1 Like