Skip to Content
0
Former Member
Jan 21, 2008 at 05:43 PM

ABAP code help

23 Views

hi folks,

I need some help in the programming code. Here is the scenario.

DATA: BEGIN OF INT_P4002 OCCURS 0,

PERNR LIKE P4002-PERNR,

VACANCY LIKE PB4002-OBJID,

END OF INT_P4002.

data: BEGIN OF int_applicant OCCURS 0,

PERNR LIKE P4002-PERNR,

contest_number_id1(10),

contest_number_id2(10),

contest_number_id3(10),

contest_number_id4(10),

contest_number_id5(10),

END OF int_applicant.

I have declared two internal tables as shown. The first table (INT_P4002 ) contains the data of applicants that have applied for multipe vacancies like (sample data). I get the data into this table by reading it from Recruitment tables.

20000010, 50001234

20000010, 50001235

20000010, 50001236

20000010, 50001237

20000011, 50001235

20000012, 50001238

20000012, 50001239

20000012, 50001240

Since each applicant has applied to different vacancies, and I am collecting the data in the form of rows. However I need to present the data along different coulmns instead of rows like this...

I now have to write this data to the table (int_applicant) in this format

20000010, 50001234, 50001235, 50001236, 50001237,

20000011, 50001235,

20000012, 50001238, 50001239, 50001240,

How can I do this?

Thanks in advance,

VG