I have a file that has lines like:
string1,string2,string3
I would like it to just be
string2
How would I use regular expression to do this?
Assuming you have strictly 3 columns, and strings do not contain comas ( ,
) and are separated by comas ( ,
), then:
find:
(.+),(.+),(.+)
replace
\2
string1,
and,string3
?