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

read/write hr infotype 2003 note

Phillip_Morgan
Contributor
0 Likes
1,328

Hi,

Does anybody know how to read or write a note (accessible through F9) from ABAP? I cannot seem to get the usual object/name values to access through READ_TEXT.

I have tried through macros without success.

Thanks for any help,

Phillip

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
1,054

Hi Phillip,

1. I could only manage to find

where the information is stored.

2. I m still finding

how to retrive it exactly.

3. Its stored in cluster table PCL1

The key will be combined

of personnel number (2102 in this case)

, the BEGDA, ENDDA

0000210200080 9999123120050801000

3. the RELID is TX (for texts)

regards,

amit m.

Hi Phillip,

1. I could only manage to find

where the information is stored.

2. I m still finding

how to retrive it exactly.

3. Its stored in cluster table PCL1

The key will be combined

of personnel number (2102 in this case)

, the BEGDA, ENDDA

0000210200080 9999123120050801000

3. the RELID is TX (for texts)

regards,

amit m.

5 REPLIES 5
Read only

Former Member
0 Likes
1,055

Hi Phillip,

1. I could only manage to find

where the information is stored.

2. I m still finding

how to retrive it exactly.

3. Its stored in cluster table PCL1

The key will be combined

of personnel number (2102 in this case)

, the BEGDA, ENDDA

0000210200080 9999123120050801000

3. the RELID is TX (for texts)

regards,

amit m.

Read only

Former Member
0 Likes
1,054

Hi Phillip,

Text will be stored in PCL1 cluster.Please see one

way of reading data from Cluster.


* Include for PCL1
INCLUDE RPC1TX00.



 CLEAR gs_p0219.
  CLEAR gt_p0219_text.
  REFRESH gt_p0219_text.

  SELECT * INTO CORRESPONDING FIELDS OF gs_p0219
   FROM pa0219
   WHERE pernr = gd_pernr
     AND subty = '5'
     AND endda = '99991231'.
  ENDSELECT.

  IF gs_p0219-itxex = 'X'.
    gs_p0219-infty = '0219'.
* Get IT0219 comments from cluster table PCL1
    CLEAR tx-key.
    MOVE-CORRESPONDING gs_p0219 TO tx-key.
    MOVE '0219' TO tx-key-infty.

    IMPORT  text-version
            ptext
            FROM DATABASE pcl1(tx)
            ID tx-key.
    IF sy-subrc = 0.
* Write out text
      LOOP AT ptext.
        WRITE ptext-line TO gt_p0219_text-text_line.
        APPEND gt_p0219_text.
        CLEAR  gt_p0219_text.
      ENDLOOP.
    ENDIF.
  ENDIF.

  

In the same way you can write using EXPORT statement to the PCL1.

Hope this is helpful to you.

Thanks&Regrads,

Siri.

Read only

0 Likes
1,054

Thank you to both. I actually got there just before reading the posts.

Here is a cleaned up example with minimum necessary:

REPORT zpm_hr_texte.

TABLES:

pcl1.

  • Need this include

INCLUDE:

rpc1tx00.

START-OF-SELECTION.

  • Fill tx-key

tx-key-pernr = 39.

tx-key-infty = 2002.

tx-key-subty = '0800'.

tx-key-endda = '20060124'.

tx-key-begda = '20060124'.

  • Did not need these

*TX-KEY-OBJPS =

*TX-KEY-SPRPS =

*TX-KEY-SEQNR =

  • import from cluster

IMPORT ptext FROM DATABASE pcl1(tx) ID tx-key.

  • Loop to view/handle

IF sy-subrc EQ 0.

LOOP AT ptext.

WRITE : / ptext-line.

ENDLOOP.

ENDIF.

Read only

suresh_datti
Active Contributor
0 Likes
1,054

Hi,

You can use HR_ECM_READ_TEXT_INFOTYPE to read the notes..

Reagards,

Suresh Datti

Read only

0 Likes
1,054

Hello,

Does anybody know:

I have to read the text of infotype 0015.

Can I use a macro and which one?

Where can I see the texts?

Hennie