Skip to Content
avatar image
Former Member

modify

Hi friends,

I am trying to modify the zspf table based on the entries in the table zsmm but it is not modifying . can you Please tell me the reason for this.

The primary key fields of zspf table is werks, npord, nplot.

For ex: my zspf table contains following entries

SS(plant) 1234(npord) 234(nplot) 7654(matnr)

I want to modify the above record to

SS 768 345 7865.

The following code I have written

SELECT SINGLE * FROM zsmm

WHERE zs = '0'.

IF sy-subrc EQ 0.

SELECT SINGLE * FROM zspf

WHERE werks = zsmm-werks

AND npord = zsmm-npord

AND plot = zsmm-nplot.

SELECT SINGLE * FROM zsdf

WHERE werks = zsmm-werks

AND npord = zsmm-npord

AND nplot = zsmm-nplot.

zspf-npord = zsmm-dpord.(IT contains value 768)

zspf-nplot = zsmm-dplot. (it contains 345)

zspf-matnr = zsmm-dmatnr.(it contains 7865)

zspf-prwerks = zsmm-werks. (it contains ss)

Modify zspf.

Thanks for your help.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • avatar image
    Former Member
    Aug 18, 2007 at 03:26 PM

    Hi Babji,

    you can't modify key fields.

    Regards,

    Clemens

    Add comment
    10|10000 characters needed characters exceeded