# BAPI_PERSDATA_GETDETAILEDLIST — List Personal Data Records (Infotype 0002)

> Returns all personal data records (infotype 0002) of a personnel number within an optional date interval. Interfaces use it to get the record keys and validity periods before changing a record. Leave the interval empty to read the whole history and check RETURN.

- Modules: HCM
- Type: BAPI
- Function group: PERS
- Remote-enabled (RFC): Yes
- S/4HANA status: Used the same way in S/4HANA
- URL: https://nekuhub.com/en/functions/bapi-persdata-getdetailedlist/

## Importing parameters

| Parameter | Type | Description | Required |
|---|---|---|---|
| EMPLOYEENUMBER | BAPIP0002-PERNR | Personnel number | Yes |
| TIMEINTERVALLOW | BAPIP0002-BEGDA | Interval start date | - |
| TIMEINTERVALHIGH | BAPIP0002-ENDDA | Interval end date | - |

## Exporting parameters

| Parameter | Type | Description |
|---|---|---|
| RETURN | BAPIRETURN1 | Return message |

## Tables parameters

| Parameter | Type | Description | Required |
|---|---|---|---|
| PERSONALDATA | BAPIP0002L | Personal data records | Yes |

## Call template (ABAP)

```abap
CALL FUNCTION 'BAPI_PERSDATA_GETDETAILEDLIST'
  EXPORTING
    employeenumber = lv_employeenumber
  IMPORTING
    return = lv_return
  TABLES
    personaldata = lt_personaldata.
```

## Related tables

PA0002

