Creating a Data Extraction Program 
Use
If you want to extract the data from the source system using the Data Transfer Workbench, you have to create a program or function module and register it with the relevant object type
.Prerequisites
You have analyzed the fields and structures as well as the data to be transferred and the transfer file in SAP format.
Procedure