2007 Jun 07 11:25 AM
Hi all,
Pleae fine below code
SELECT * FROM PA0001 INTO TABLE ITAB
WHERE WERKS = PER_AREA
AND BTRTL = SUB_AREA.
I was trying to select all personnel numbers with in particuler sub area and personnel area.
But surpsisingly, I above statement reading some funny vaues when I check with table. what would be reason?
Thanks
Shiva.
Hi all,
Pleae fine below code
SELECT * FROM PA0001 INTO TABLE ITAB
WHERE WERKS = PER_AREA
AND BTRTL = SUB_AREA.
I was trying to select all personnel numbers with in particuler sub area and personnel area.
But surpsisingly, I above statement reading some funny vaues when I check with table. what would be reason?
Thanks
Shiva.
2007 Jun 07 11:27 AM
Hi,
ITAB should be the same Structure of the table PA0001.
DAta: ITAB like PA0001 occurs 0 with header line.
Regards
Sudheer
2007 Jun 07 11:29 AM
Hi,
Both the fileds you are using the WHERE clause are not part of the primary key, so you can expect some wierd results check the table key and improve your where clause.
Regards,
Sesh
2007 Jun 07 11:30 AM
1. you are comparing character fields, so check accordingly.
2. pass a date range to get employees list, since in HR data is based on date.
2007 Jun 07 11:31 AM
Hi,
In the where clause ,check,
WERKS = PER_AREA and
BTRTL = SUB_AREA.
per_area and sub_area should be of same type as werks and btrtl.
regards
2007 Jun 07 11:36 AM
Hi Shiva ,
Could you please tell what value are you getting , so that we can help you better.
Funny values is too vague to suggest what can be the reason for the statement not working correctly.
Regards
Arun
2007 Jun 07 11:40 AM
Hi shiva
DATA:epernr like pa0001-pernr,
ename1 like pa0001-ename.
DATA : int_pa0001 LIKE pa0001 OCCURS 0 WITH HEADER LINE.
CALL FUNCTION 'HR_TMW_GET_EMPLOYEE_NAME'
EXPORTING
person_no = PA0001-PERNR
IMPORTING
EDIT_NAME = PA0001-ENAME
* NAME_WITH_NO =
.
IF sy-subrc = 0.
READ TABLE out_tab60 INDEX 1.
out_tab60-value = PA0001-ENAME(11).
MODIFY out_tab60 INDEX 1.
ENDIF.
ENDFORM. "CHEQUE_JNTVENT
Reward if helpfull
Regards
Pavan
| User | Count |
|---|---|
| 3 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 | |
| 1 |