I don't think you can do regular expressions natively in Excel and I get the impression this will require some VBScript, which I don't know.
I have a dataset which includes strings of the following format in a given column
123 foo, 234-bar, 345 baz , ...
I want to extract the numbers at the beginning of each comma-separated record and sum them in another column.
If we split the string on commas and consider substrings, I think this will suffice as a regex
^\D*?(\d+)?\D*/
(Only the first of multiple numbers should be considered and a numberless string should extract empty and be considered zero.)
Here is the expected output from some sample data
INPUT OUTPUT
-------------------------------------
5-foo, 10 bar 15
11 baz, 11
bad,string 0
hello,123,100, 100 ,xxx 323
How do I make Excel perform this calculation?