Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Reading Data From Change Tables:

I need to read data from Change Tables:

My Primary requirement is to Find all updated CONTRACT VALUES (<b>AMTBL</b>), BEGIN DATE (<b>GUEBG</b>) and END DATE (<b>GUEEN</b>) from table VBAK in a particular date range.

I tried the following code: But it has become a really bad performance issue.

SELECT objectid changenr

FROM cdhdr INTO TABLE t_cdhdr

WHERE objectclas = 'VERKBELEG'

AND udate IN so_erdat

AND tcode = 'VA42'.

SELECT objectid changenr fname value_old value_new

FROM cdpos

INTO TABLE t_cdpos

FOR ALL ENTRIES IN t_cdhdr

WHERE objectclas = 'VERKBELEG'

AND objectid = t_cdhdr-objectid

AND changenr = t_cdhdr-changenr

AND tabname = 'VBAK'

AND fname in ('GUEEN' , 'AMTBL' , 'GUEBG')

AND chngind = 'U'.

Can you please guide me in the right way to make it performance effective.

Tags:
Former Member
Not what you were looking for? View more on this topic or Ask a question