|
Fetch the rows with match string on a fixed lenth text file - NO delimiters
Hi
I am trying to fetch the rows with match string "0000001234"
Input file looks like below:
09 0 XXX 0000001234 Z 1
09 0 XXX 0000001234 Z 1
09 0 XXX 0000001234 Z 1
09 0 XXX 0000001234 Z 1
09 0 XXX 0000001234 Z 1
09 0 XXX 0000001234 Z 1
here the scenario is like we need to fetch the rows with match string "0000001234" and print the lines in a separate file ...
i tried with grep command by grep ^09 file > output file it works fine only when the string is starts first.
Please can some one help me how we can do this ...
|