In each line in I want to replace last two commas with dots
I found such two sed piped method but it does not work with sed on MacOS
$ echo 'abc,def,12379,foo' | sed 's/\(.*\),/\1./'|sed 's/\(.*\),/\1./' abc,def.12379.foo
Would there be a way which will work with any sed version? Not necessarily with sed only.