cancel
Showing results for 
Search instead for 
Did you mean: 

ITAB problem

former_member193357
Participant
0 Kudos
56

hiii

DATA: BEGIN OF itab occurs 0,

col1(20) ,

END OF itab.

my itab consist of 3 records.

eg::

itab-col1

abc

bcde

ccc

Now i want all the 3 records (i.e itab-col1) in one variable(say var).

eg::: var = abc bcde ccc.

<b>SO how to do this.</b>

Thanking you.

Regards.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Try this.

Loop at itab.

concatenate var1 itab-col1 into var1.

endloop.

Award points if useful.

Answers (4)

Answers (4)

former_member193357
Participant
0 Kudos

thank all

JozsefSzikszai
Active Contributor
0 Kudos

hi Hemant,

DATA : text TYPE string.

LOOP AT itab.

CONCATENATE text itab-col1 INTO text SEPARATED BY space.

ENDLOOP.

hope this helps

ec

Former Member
0 Kudos

data: var type string.

loop at itab.

concatenate var itab-col1 into var.

endloop.

Former Member
0 Kudos

If u have only 1 col in itab use like this.

loop at itab.

concatenate var itab-col1 into var seperated by space.

endloop.