Google Sheets/Regex - How to pull all numbers that start with # -


i have google sheet cell reads:

ticket no. #3223 ticket no. #2334 ticket no. #4005 

is there way pull numbers starting #, not include #? results example:

 3223  2334  4005 

thank assistance

yes can use this:

=regexreplace(a1,"(\d+)(\d+)","$2"&char(10)) 

the parenthesis capture group doing saying replace non-digits \d+ in first capture group, digits \d+ in second capture group. char(10) @ end gives new line.

if want them in separate cells can change &char(10) ; , use split , transpose stack them:

=transpose(split(regexreplace(a1,"(\d+)(\d+)","$2;"),";")) 

enter image description here


Comments

Popular posts from this blog

javascript - Slick Slider width recalculation -

jsf - PrimeFaces Datatable - What is f:facet actually doing? -

angular2 services - Angular 2 RC 4 Http post not firing -