Skip to Content
0
May 12, 2016 at 01:14 AM

Update value to NAST table return false

145 Views

Hi Expert,

I want to populate the 'zvalue' in one of unused field in NAST table. This logic I did in FM 'RV_MESSAGE_UPDATE', then, it will call the zprint program, and 'zvalue' will be used in the print program. Unfortunately, it cause an error in update.

Below is example of my code:

DATA: LV_COUNT TYPE NAST-PMID1.

LV_COUNT = '2'.

UPDATE NAST

SET PMID1 = LV_COUNT

WHERE KAPPL = NAST-KAPPL

AND OBJKY = NAST-OBJKY.

IF SY-SUBRC = 0. --------->>> SY-SUBRC = 4.

COMMIT WORK.

ELSE.

ROLLBACK WORK.

ENDIF.

My question are:

1)Can we modify NAST table? If can, how we can modify it?

2)Else, is there is any way so that i can pass the total number of invoices that has been generated in VF04 to the zprint program?

Please advice,

Thanks and regards.