Quote:
Originally Posted by
Franklin52
I really don't understand the problem.
Is the output in my last post not the desired output?
Sir, it was only changing the 1st occurrence of the rank field.
i.e. was getting |1|9.1| ... but then the next values continued to be the same
i.e. |2.|9.1| ....
I made the following change and now its working fine
sed 's/\.|/|/'
Thanks a lot everyone !!
---------- Post updated at 03:14 PM ---------- Previous update was at 08:36 AM ----------
How to use grep to retrieve a particular column.
Like for the following intermediate o/p:
29|8.6|North by Northwest|1959|83372
30|8.6|Se7en|1995|244038
31|8.6|Its a Wonderful Life|1946|90888
32|8.6|The Lord of the Rings: The Two Towers|2002|292149
33|8.6|Citizen Kane|1941|126588
the 1st column is the rank of movie, 2nd is the rating and 3rd is the Movie name.
I need to retrieve the 3rd column using grep and count no. of words in the movie name.
How to go about this?
---------- Post updated at 07:38 PM ---------- Previous update was at 03:14 PM ----------
Hiii... Can anyone please help out?