我有以下这些行的文件:
"A,B,C,D","E","F","G","H"
如何轻松删除配额中的第一列?
最后我想看看:
"E","F","G","H"
答案 0 :(得分:2)
sed 's/^"[^"]*",//' YourFile
假设:
\"
,
之间没有额外的空格(在这种情况下很容易适应)答案 1 :(得分:0)
也尝试这种方式
sed 's/^"[^"]\+",//' FileName.txt
<强>输出:强>
"E","F","G","H"
答案 2 :(得分:0)
awk -F'[",]' -v OFS=\",\" '{print "\""$5,$6,$7,$8"\""}' file
"E","F","G","H"