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

Update Multiple Z-tables

Former Member
0 Likes
679

Hi Experts,

We need to update/upload data into Multiple tables which are related to each

other, and the DATA is to be entered in to the corresponding fields depending upon the relationship between tables.

Req: Updates to the table that contains the job details and also the job steps as well. Need to be consistent

Tables : zjobinfo , zjobrun and zjobstep.

These three tables have multiple fields.

Here Jobname is one of the Key fields in these tables.

Around 2000 records are to be updated/uploaded.

Kindly let know how to proceed.

Regards,

Ajaz

Hi Experts,

We need to update/upload data into Multiple tables which are related to each

other, and the DATA is to be entered in to the corresponding fields depending upon the relationship between tables.

Req: Updates to the table that contains the job details and also the job steps as well. Need to be consistent

Tables : zjobinfo , zjobrun and zjobstep.

These three tables have multiple fields.

Here Jobname is one of the Key fields in these tables.

Around 2000 records are to be updated/uploaded.

Kindly let know how to proceed.

Regards,

Ajaz

4 REPLIES 4
Read only

Former Member
0 Likes
617

same question again,

check your query in ABAP general, i have pastred a code which might be useful to you

cheers

Ajay

Read only

Former Member
0 Likes
617

HI Friend ,

1) You Create a module pool program where you can bring many tables i.e. fields from the corresponding tables

2) Create a button name 'Submit' and PAI write insert command query

3) Create a Transaction code, Activate it and Test it .

Then by using LSMW or BDC you can Upload the data by using the Transaction code which you created.

Regards,

Surjith Kumar P

Read only

Former Member
0 Likes
617

Hi Syed,

Create a View to solve your purpose.

Regards,

George

Read only

Former Member
0 Likes
617

TABLES: zxxxx1,zxxxx2.

DATA: int_zxxxx like zxxxx occurs 0 with header line.

-


-


loop at int_zxxx

UPDATE zxxx1

set:

z_ACTUAL_QTY = int_zxxx-z_ACTUAL_QTY

Z_MANUAL_QTY = int_zxxx-Z_MANUAL_QTY

z_DELV = int_zxxx-Z_DELV

z_RECPT = INT_zxxx-Z_RECPT

Z_CLOSE_QTY = INT_zxxx-Z_CLOSE_QTY

AENAM = INT_zxxx-AENAM

AEDAT = INT_zxxx-AEDAT

where

exgnum = int_zxxx-exgnum and

matnr = int_zxxx-matnr and

spmon = int_zxxx-spmon.

if SY-SUBRC = 0.

Message I999(ZZ) with 'RECORD MODIFIED'.

else.

Message I999(ZZ) with 'ERROR MODIFYING RECORD'.

ENDIF.

UPDATE zxxx2

-


-


endloop.