Hi
i want to match 12,345 in the following string: adf99fgl12,345qsdfm34
In general case, i have a number (a price) with a comma, in a string that contains numbers, letters, and other symbols, but no other commas. I want to tell sed to extract the price, that is to say, all number before and after the comma, and the comma.
The closest expression i found was:
echo adf99fgl12,345qsdfm34 | sed "s/[^0-9]*\([0-9]+,[0-9]*\)[^0-9]*/\1/"
Thank you