Extracting substring using RegEx

Mike_Gr

New Member
Joined
Nov 14, 2012
Messages
15
I've been trying to learn RegEx in Excel 2013 in order to extract certain substrings from long strings of text. The strings are all in the same column and excel sheet. The solution to my problem is probably quite simple one but I can't quite seem to make the operation work. (I also attempted to use the more trivial functions FIND, RIGHT etc which would work for this but are a bit messier and RegEx also seems like a nice tool which may be useful for more complex tasks in the future).

What I want to do is extract information that is positioned anywhere in the string after an occurence of the text "issue": (including quotation marks and colon) and before a comma (which should therefore be used as an end delimiter). The information retrieved can be both numbers, letter and dashes and the length will vary.

There is only one occurrence of "issue": in every cell so there's no need to repeat the procedure after a result is fetched. Some cells are also missing the information and should simply be skipped.

If someone can provide me with at code snippet or point me in the right direction to an appropiate learning resource it would be greatly appreciated.
 

Excel Facts

Which Excel functions can ignore hidden rows?
The SUBTOTAL and AGGREGATE functions ignore hidden rows. AGGREGATE can also exclude error cells and more.
Hi Mike

2 questions: Is all the text you are looking for in 1 line or can it span several lines? Is there just 1 comma after the "issue": till the end of text or can there be more commas?
If the answer is yes to both questions then Derek's pattern should do it.
 
Upvote 0
Thanks for your kind replies! There are no line breaks in the text but there are more commas so that needs to be taken into account.
 
Upvote 0

Forum statistics

Threads
1,223,885
Messages
6,175,178
Members
452,615
Latest member
bogeys2birdies

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top