Skip to Content
0
Former Member
Mar 13, 2007 at 04:42 PM

rp-read-infotype is not picking the locked data

310 Views

Hi

I am trying read the maintain text that users inserts from PA30 over view screen. When the user edits the salary record it creates a copy of the original and puts it on locked. so I have two records with same Begda and Endda and pernr in PA0008 with one locked and another open. Since the user is putting the text whe they edit the salary The locked on got the text the other one don't.

Here is my code to read it but the macro only picks the one that is not locked. can any one tell me how to pick both the records? or better the locked one?

report  zp_pa_infty_read_text.
tables:
 pernr.
infotypes:
 0008.

selection-screen begin of block abc with frame title text-001.
parameters:
               p_pernr like pernr-pernr,
               p_date like sy-datum.
selection-screen end of block abc.

data:  key like pskey.
data: begin of ptext occurs 200.
data:   line(78).
data: end of ptext.

rp-read-infotype p_pernr 0008 p0008 p_date '99991231'.
loop at p0008 where itxex eq 'X'.
  refresh ptext.
  move-corresponding p0008 to key.

  import ptext from database pcl1(tx) id key.

  loop at ptext.
    write :/ p_pernr,ptext-line.
  endloop.
endloop.