Hi Experts,
i need to change delimiter from tab to ","
sample test file
cat test
A0000368 A29938511 072569352 5 Any 2 for �1.00 BUTCHERS|CAT FOOD|400G Sep 12 2012 12:00AM Jan 5 2014 11:59PM Sep 7 2012 12:00AM M 2.000 group 5
output
A0000368","A29938511",072569352,"5"," Any 2 for �1.00","BUTCHERS|CAT FOOD|400G","Sep 12 2012 12:00AM","Jan 5 2014 11:59PM","Sep 7 2012 12:00AM","M","2.000","group","5
i have used below codes
awk -F "\t" 'BEGIN {OFS="\",\""} {print $1,$2,$3,$4,$5,$6,$7,$8,$9,$10,$11,$12,$13}' test
now is there anyway without giving all field from $1 to $13 i can achieve same result in awk.
there is way in sed like below
sed 's/ /","/g'
but i dont want to use sed.