I'm using Amazon Linux with bash shell.  I have a file with comma delimited data, where each row looks like this2049,576804C7DF554416A9EA25B2A5A81514,X,Then I have a second file, with comma delimited data, in which each row looks like thisid,user_name,user_emailEvery row in the second file will be unique.  My question is, how do I take every row from the first file, and replace the second token with matching data (based on matching the second token from the first file with the first token from the second file) from the second file?  So for instance the lien I listed above would become2049,576804C7DF554416A9EA25B2A5A81514,username1,email1,X,Assuming that 576804C7DF554416A9EA25B2A5A81514 could be located in the second file.
How do I replace tokens from one file with data from another?
shell script;text processing;csv;search;replace