Add double quotes around fields in AWK script output?

前端 未结 6 1419
臣服心动
臣服心动 2021-02-04 01:33

I have written an awk script that converts a distributor flatfile into a CSV importable into Magento. This file is semi-colon delimited.

It is not putting quotes around

6条回答
  •  闹比i
    闹比i (楼主)
    2021-02-04 01:54

    awk '{for (i=1;i<=NF;i++) $i="\""$i"\""}1' FS=";" OFS=";" input
    

提交回复
热议问题