How can I replace a substring within a string? For example, if a line consists of different words separated from each other by comma, such as in:
file,tcp,ftp,SF,5,6,3,normal.
How can I locate the second word (identified by 1st and 2nd commas) and replace that word with a number of my choice?