From: T E Schmitz <mailreg@numerixtechnology.de>
To: pgsql-sql@postgresql.org
Subject: SELECT substring with regex
Date: Fri, 07 Jul 2006 14:51:28 +0100
Message-ID: <44AE66E0.1040606@numerixtechnology.de> (raw)
I would like to split the contents of a column using substring with a
regular expression:
SELECT
substring (NAME, '^\\d+mm') as BASE_NAME,
substring (NAME, ??? ) as SUFFIX
FROM MODEL
The column contains something like
"150mm LD AD Asp XR Macro"
I want to split this into
"150mm", "LD AD Asp XR Macro"
How can I extract the bit following the matching substring?
--
Regards,
Tarlika Elisabeth Schmitz
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-sql@postgresql.org
Cc: mailreg@numerixtechnology.de
Subject: Re: SELECT substring with regex
In-Reply-To: <44AE66E0.1040606@numerixtechnology.de>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox