0
Hi, I have a problem I need to solve. I have a file that should be inserted exactly one column of another file, I’m trying as follows:
cat $1 | cut -d ',' -f2 | tr "/" "-" | awk -F "-" '{print $2"-"$1"-"$3}' > temp.txt
cat $1 | sed 's/[0-3][0-9]\/[0-1][0-9]\/[0-9][0-9][0-9][0-9]/temp.txt/'
Of which temp.txt is the file that has the updated column. The problem is that instead of replacing the specified column, it is overwriting with the file name "temp.txt". Any suggestions to fix this? Or another way to do it? Thank you!
Can you explain better? I don’t quite understand your problem.
– Roknauta
my problem is as follows: Change the column to "Year-Month-Day" Example: convert from 12/22/2012 to 2012-12-22
– Eryc Masselli
Edit the question....
– Roknauta
I generated a file with the change called tempo.txt, in 12-22-2012 format. I need to insert this file in the second column of another file. csv
– Eryc Masselli