Using regex in WHERE in Postgres
Write instead:
select * from table where name ~ 'foo'
The '~' operator produces a boolean result for whether the regex matches or not rather than extracting the matching subgroups.
Write instead:
select * from table where name ~ 'foo'
The '~' operator produces a boolean result for whether the regex matches or not rather than extracting the matching subgroups.