09-09-2008 8:48 PM
Hi,
I want to read the records from q0006. Please the req below.
Concatenate Telephone number area code (Q0006-AREAX) and Telephone number (Q0006-TELNX) where Address Type (P0006-ANSSA) = "1" (Permanent residence) and Communications Type (P0006-COMXX) = "TEL1".
Thanks.
09-09-2008 8:49 PM
Use FM
HR_READ_INFOTYPE
DATA RETCD LIKE SY-SUBRC.
DATA: P0006 LIKE P0006 OCCURS 0 WITH HEADER LINE.
CALL FUNCTION 'HR_READ_INFOTYPE'
EXPORTING
TCLAS = 'A'
PERNR = EMPLOYEENUMBER
INFTY = '0006'
BEGDA = TIMEINTERVALLOW
ENDDA = TIMEINTERVALHIGH
IMPORTING
SUBRC = RETCD
TABLES
INFTY_TAB = P0006
EXCEPTIONS
INFTY_NOT_FOUND = 1
OTHERS = 2.
split for Area code and number is
wa_ca-areac = wa_ca-telnr+0(3).
wa_ca-telnr = wa_ca-telnr+3(11).
09-09-2008 8:49 PM
Use FM
HR_READ_INFOTYPE
DATA RETCD LIKE SY-SUBRC.
DATA: P0006 LIKE P0006 OCCURS 0 WITH HEADER LINE.
CALL FUNCTION 'HR_READ_INFOTYPE'
EXPORTING
TCLAS = 'A'
PERNR = EMPLOYEENUMBER
INFTY = '0006'
BEGDA = TIMEINTERVALLOW
ENDDA = TIMEINTERVALHIGH
IMPORTING
SUBRC = RETCD
TABLES
INFTY_TAB = P0006
EXCEPTIONS
INFTY_NOT_FOUND = 1
OTHERS = 2.
split for Area code and number is
wa_ca-areac = wa_ca-telnr+0(3).
wa_ca-telnr = wa_ca-telnr+3(11).
09-09-2008 9:02 PM
Thanks for the quick reply... How can I connect this two tables... and get the data..
09-09-2008 9:14 PM
All the data is stored in table PA0006. you can use the above function module to read the table. This FM will return you a table in which all the info you need is there.
A
03-08-2011 2:22 PM
Hi,
when we go to the infotype 0006 from pa30 and select f1 help on Q0006-AREAC,
but Q0006 is a structure and there is no field with name AREAC in the table PA0006,
how can we fetch the data for that and what is the table for that structure.
plz help me to know this.
Thanks and Regards
Zarah
03-08-2011 2:26 PM
Hi
Answers for all your questions are available in the above posts. Let us know if you need anything else apart from this.
Regards
Ranganath