I want get characters between [] from a string
example:
"hello" and "world"
from
"gegerferf[hello] frfer [world] frfre rfrf"
into a table
i am try with substring and for loop but i dont now.
select regexp_replace(string, '...','', 'g')
from mytable
The question didn't provide an example of the expected results, so I'll present a couple of options.
The following is run to setup the demonstration context:
This query returns the text between brackets concatenated into a single string:
The result is:
This query returns the text between brackets as separate rows:
The output is: