DS Enhancement
DS Enhancement
This document explains about enhancing a datasource with new ZZ field and gets it populated
from the underlying database table.
This document has been explained with an example. You can create new one based on this
document.
Datasource information:
Kindly follow the procedure as shown in the screenshots below to get it done which is self
explanatory:
If the extract structure does not have append structure in it, then create new append structure.
We need to include the below mentioned field in the datasource from the table EKPO.
Enter the unique component name starts with ZZ.
If append structure already exist in extract structure, then include new filed in that existing
append structure.
Again got RSA6 and select your datasource and click on display.
But the hide field and Field only are marked. So, we need to uncheck both the fields. Or else
those fields will not be replicated to BW side.
Uncheck those two fields.
We have done with the creation of new filed in the datasource. Now we need to populate the field
with the values from the table field EKPO- TXJCD which is from different table.
Note: Enhancement RASP0001 can be assigned to only one project. So, we need to search for that
project.
Click on Components.
You can see four function calls. Each function call is intended for different datasource type.
Double click the first function since we are enhancing transactional datasource.
In the source code tab Double click on include program as shown below:
TABLES: ekpo.
DATA: l_s_icctrcst LIKE s001biws,
l_counter,
l_s_icctract LIKE icctract,
l_s_icctrsta LIKE icctrsta,
l_tabix LIKE sy-tabix.
CASE i_datasource.
WHEN ‘ZBI_EKKO_AK’.
IF sy-subrc = 0.
l_s_zoxid30165-zztaxjrdn = ekpo-txjcd.
MODIFY c_t_data FROM l_s_zoxid30165 INDEX l_tabix.
ENDIF.
ENDLOOP.
Activate the include program after completion of coding and come out of the screen.
Now its time for testing to check whether the field is getting populated with values.
Enter the datasource name and some entries for particular document number which contains value
for newly added field. Click on execute.
It extracted one entry from the table EKKO.
Click on ALV grid to display the record.
The newly added field “Tax jurisdiction” got populated with value from the table EKPO.