Search code examples
regexgoogle-sheetsgoogle-sheets-formularegex-groupregex-greedy

Regex to individuate entries separate by specific character


I'm using Google Sheets and attempting to individuate the entries separated by [char10] >

Sample content from a cell:

> low confidence registrar [char10] > No SSL certificate [char10] > Malicious intent [char10] > Complete sentence #4 [char10]

Closest I got so far was using the following Regex:

"> (.*?) !"

which only yields the first entry.

How do I fix my regex to yield the many groups and separate them into different columns?

Example: REGEXEXTRACT(H15:H,"> (.*?) !")


Solution

  • use:

    =INDEX(SPLIT(SUBSTITUTE(H15:H, "> ", ), CHAR(10)))
    

    enter image description here