I am trying to extract the ip address from "[223.104.227.42]". I want to extract the 223.104.227.42 between '[' and ']', Im using this query:
select regexp_extract('[223.104.227.42]', '\\[(.*?)\\]')
But I get an error:
FAILED: In function regexp_extract, pattern must has one group reference at least.