Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

find the value using regular expresiion

tarangini_katta
Active Contributor
0 Likes
727

Hi All,

I have a requiremnt in FInd statment using REGEX.

i have values like this

B1;;2009/11 Claim: 007324;SA;20081006;20091101;I004;;1032000MAR;;750;31;500481;Michael 30/07/2008;999999;EUR;247.79;007324;;;;;;K;;;FIE01240;FB01;S178740019800000011;J;200911;;

I want to find 'I004' in this record using Find Regular expressions

with out using classes.

Can anybody please help me.

Thanks

Hi All,

I have a requiremnt in FInd statment using REGEX.

i have values like this

B1;;2009/11 Claim: 007324;SA;20081006;20091101;I004;;1032000MAR;;750;31;500481;Michael 30/07/2008;999999;EUR;247.79;007324;;;;;;K;;;FIE01240;FB01;S178740019800000011;J;200911;;

I want to find 'I004' in this record using Find Regular expressions

with out using classes.

Can anybody please help me.

Thanks

6 REPLIES 6
Read only

Former Member
0 Likes
693

DATA: itab4 TYPE TABLE OF string,

results TYPE match_result_tab.

data: v_var2 type string.

data: mcnt type i.

v_var2 = 'B1;;2009/11 Claim: 007324;SA;20081006;20091101;I004;;1032000MAR;;750;31;500481;'.

append v_var2 to itab4.

FIND ALL OCCURRENCES OF 'I004'

IN TABLE itab4

MATCH COUNT mcnt

RESULTS results.

Edited by: abap on Feb 4, 2009 10:35 AM

Read only

0 Likes
693

HI,

I want to write the expression using REGEX.#

Thanks

Read only

0 Likes
693

hi,

just include regex

FIND ALL OCCURRENCES OF REGEX 'I004'

IN TABLE itab4

MATCH COUNT mcnt

RESULTS results.

Read only

0 Likes
693

Hi,

REGEX is not a simple expresssion.I know how to write find but REGEX contains special charcters.

The value may be 'i004' or anything.I want to find it dynamically using FIND regex.

Thanks

Read only

Former Member
0 Likes
693

hi,

can explain in detail.

DATA l_string TYPE string.

l_string = '!@@##$%'.

REPLACE ALL OCCURRENCES OF REGEX '[^[:word:]]' IN l_string WITH 'Y'.

Edited by: abap on Feb 4, 2009 11:52 AM

Read only

tarangini_katta
Active Contributor
0 Likes
693

solved my self.