Oracle Regular expression function-regexp_like use example

Source: Internet
Author: User

The original in this poke

Regexp_like

3 parameters

The first one is the string entered

The second one is the regular expression

The third is the range of values:

I: case is not sensitive;

C: Case sensitive;

N: Point number. Do not match line break symbols;

M: multi-line mode;

X: Extended mode, ignoring white-space characters in regular expressions.

All test data

Sql> SELECT * from Test_reg_like;

A

----------------------------------------

Abc

A12

12a12

Match Letter A of the

Sql> SELECT

2 *

3 from

4 Test_reg_like

5 WHERE

6 Regexp_like (A, ' a ');

A

----------------------------------------

Abc

A12

Match Letter A of the (not case sensitive)

Sql> SELECT

2 *

3 from

4 Test_reg_like

5 WHERE

6 Regexp_like (A, ' a ', ' I ');

A

----------------------------------------

Abc

A12

12a12

Match Letter A back with 1 . One or more numbers. (not case sensitive)

Sql> SELECT

2 *

3 from

4 Test_reg_like

5 WHERE

6 Regexp_like (A, ' a\d+ ', ' I ');

A

----------------------------------------

A12

12a12

Match Letter A the beginning, the number ending

Sql> SELECT

2 *

3 from

4 Test_reg_like

5 WHERE

6 Regexp_like (A, ' ^a.+\d$ ');

A

----------------------------------------

A12

Oracle Regular expression function-regexp_like use example

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.