Perl like regular expression in Oracle DB

There's regular expression support in Oracle DB

Using Regular Expressions in Database Applications
Oracle SQL PERL-Influenced Extensions to POSIX Standard
But '\b' is not supported which I believe is quite wideliy used in perl and/or other tools

perlre - perldoc.perl.org
\b Match a word boundary
So, I experimented with '\W' which is non-"word" character
When combined with beginning-of-line and end-of-line like below, I think it works exactly the same as '\b'
SELECT * FROM TAB1 WHERE regexp_like(TEXTCOL1, '(^|\W)a_word($|\W)', 'i')




Comments:

Post a Comment:
  • HTML Syntax: NOT allowed
About

The views expressed on this blog are my own and do not necessarily reflect the views of Oracle.

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today