I am trying to separate a repeated substring from a really long string. I cannot use the offset numbers because they are all variable length. I want to split into substrings using particular delimiters, for example, (code given below), I want the parts from > to the first \n after the > in one string, and \n to the next > in another string.
Using split seems way too cumbersome and would need too many statements.
Substr function requires length or offset, but they are variable.
Is there a shorter way?