I need a regex that extract text inside a delimiter but I'm having problem extracting the value inside the delimiter [DATA n] and [END DATA]
Here's my regex
(?<=\[DATA\s+\d+\]).*(?=\[END DATA\])
Here's example data I want to match
Some text here
[DATA 1]
data one
some more data
[END DATA]
[DATA 2]
data two
more data
data
[END DATA]
[DATA n]
more data
data
[END DATA]