sql >> Base de Datos >  >> RDS >> PostgreSQL

Cómo separar texto usando subcadena

SELECT
  a[2] AS FirstName,
  a[1] AS LastName,
  a[3] AS ID
FROM (
  SELECT regexp_matches(column_name, '(.+), (.+) \((.+)\)')
  FROM table_name
) t(a)